Text Form Field

J

Joel

Why can't I make 2 text form fields with the same bookmark
in the same .dot file? Is there a way to do it. I just
want 2 identical Text Form Fields in the same file.

Thanks - Joel
 
G

Graham Mayor

Bookmarks have to be unique, but you can reproduce the content of a bookmark
using REF fields as often as you wish. If you set the information from the
first form field, check its 'calculate on exit' property - the REF field(s)
will be populated by the same information.

--
<>>< ><<> ><<> <>>< ><<> <>>< <>>< ><<>
Graham Mayor - Word MVP

Web site www.gmayor.com
Word MVP web site www.mvps.org/word
<>>< ><<> ><<> <>>< ><<> <>>< <>>< ><<>
 
P

Peter Jamieson

Why can't I make 2 text form fields with the same bookmark
in the same .dot file?

Probably for the same reason that you can't have two pieces of text
bookmarked with the same bookmark name. At any one time, a given bookmark
only marks one area of a document. Even if you have multiple { SET
mybookmark } fields in a document, the boomark will correcspond to the last
SET field to be executed.
Is there a way to do it.

I doubt it. Even if you save a .doc as .rtf and edit the plain text to give
two form fields the same name, Word just blanks one of them out when you
open the .rtf.
I just
want 2 identical Text Form Fields in the same file.

Maybe you have the wrong expectation of what a bookmark will do for you -
but if you can tell us what you are trying to achieve, maybe we can suggest
an alternative.
 
P

Peter Jamieson

As Graham says in a nearby message, typically you would use a form field for
the first of the two amount fields you need. Specify "Calculate on exit" in
its properties. Then for the second field, use a REF field which references
the bookmark name you specify in the first field.
 
J

Joel

Excellent. It worked. One problem though, how come it is invisible until I
hit print preview? I did check the box on the bookmark "Calculate on exit".

Thanks - Joel
 
G

Graham Mayor

Sometimes fields are reluctant to update - this is easily solved with a
simple macro run on exit from the field. As print preview works for this
here, then:

Sub UpdateFields()
Options.UpdateFieldsAtPrint = True
Application.ScreenUpdating = False
PrintPreview = True
PrintPreview = False
ActiveDocument.ActiveWindow.View.Type = wdPrintView
Application.ScreenUpdating = True
End Sub

should do the trick.

See http://www.gmayor.com/installing_macro.htm where the example code is an
alternative and more thorough update macro.

--
<>>< ><<> ><<> <>>< ><<> <>>< <>>< ><<>
Graham Mayor - Word MVP

Web site www.gmayor.com
Word MVP web site www.mvps.org/word
<>>< ><<> ><<> <>>< ><<> <>>< <>>< ><<>
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top