View Single Post
 
Old 02-15-2016, 12:10 AM
macropod's Avatar
macropod macropod is offline Windows 7 64bit Office 2010 32bit
Administrator
 
Join Date: Dec 2010
Location: Canberra, Australia
Posts: 22,467
macropod has a reputation beyond reputemacropod has a reputation beyond reputemacropod has a reputation beyond reputemacropod has a reputation beyond reputemacropod has a reputation beyond reputemacropod has a reputation beyond reputemacropod has a reputation beyond reputemacropod has a reputation beyond reputemacropod has a reputation beyond reputemacropod has a reputation beyond reputemacropod has a reputation beyond repute
Default

Bookmark the first table (e.g. Tbl1) then use a formula field to return the MAX value. For example, a formula field coded as:
{=MAX(Tbl1 C:C)}
will return the maximum value in column C of the table bookmarked as Tbl1. No macros required.

If the values in the first table are being inserted via formfields, checking their 'calculate on exit' property will cause the MAX formula to update every time one of the formfields updates; otherwise, pressing Ctrl-A, F9 will update all fields in the document and selecting just the result returned by the max formula and pressing F9 will update that. Checking Word's 'update fields before printing' option will also ensure the calculation updates at print time.

Note: The field brace pairs (i.e. '{ }') for the above example are all created in the document itself, via Ctrl-F9 (Cmd-F9 on a Mac); you can't simply type them or copy & paste them from this message.
__________________
Cheers,
Paul Edstein
[Fmr MS MVP - Word]
Reply With Quote