Home | Contact Us | FAQ | Search & Site Map | Link to Us
Sign In | Join | Other 45 Sites in Network
Home
DiscussionsAccessExcelInfoPathOutlookPowerPointPublisherWord
DirectoryUser Groups
Related Topics
Outlook ExpressInternet ExplorerWindowsMS Server ProductsMore Topics ...

MS Office Forum / Word / Programming / February 2007

Tip: Looking for answers? Try searching our database.

Field Update

Thread view: 
Enable EMail Alerts  Start New Thread
Thread rating: 
Peter Huber - 22 Feb 2007 15:17 GMT
Hello

I wand to update all my fields in a document with the following code:

Dim f as Field
For each f in ActivDocument.Fields
   f.Update
next

It's working fine with one exception: the field NumPages.

I have deleted one page, but the field doesn't update properly. With F9 it
works but the generated code
"Selection.Fields.Update" doesn't work too.

The field is placed in a normal first section and there is no protection.

Have you any suggestions?

Thanks Peter
Doug Robbins - Word MVP - 22 Feb 2007 19:38 GMT
Easiest way is to use

With ActiveDocument
   .PrintPreview
   Close PrintPreview
End With

Signature

Hope this helps.

Please reply to the newsgroup unless you wish to avail yourself of my
services on a paid consulting basis.

Doug Robbins - Word MVP

> Hello
>
[quoted text clipped - 16 lines]
>
> Thanks Peter
 
Sign In
Join
My Latest Posts
My Monitored Threads
My Blog
My Photo Gallery
My Profile
My Homepage

Start New Thread
Enable EMail Alerts
Rate this Thread



©2008 Advenet LLC   Privacy Policy - Terms of Use
This website includes both content owned or controlled by Advenet as well as content owned or controlled by third parties.