Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations SkipVought on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Word 97 Form Field Update 1

Status
Not open for further replies.

CAUFred

MIS
Mar 22, 2001
12
0
0
US
Using Office 97 Pro, I am creating a form in Word that has Check Boxes on page 1. I need to place the character "X" on page 2 of the form if a box is checked. I have tried to use the INSERT/FIELD on page 2 (IF Check1=YES X O) to post the "X" on page 2 with no luck. It will not change the result of the IF statement no matter what the value of Check1 is. What am I missing??? When does Word do Form Field updates????
 
I'll have a go because no one's answered this (but there may be a better way)

Try an on exit macro for the checkbox.

Make sure you have text field on page two (where the X is to go) that has a bookmark name of Page2X.

Create the following macro.

Sub XonPage2()

If ActiveDocument.FormFields("Check1").CheckBox.Value = True Then
ActiveDocument.FormFields("Page2X").Result = "X"
Else
ActiveDocument.FormFields("Page2X").Result = " "
End If
End Sub

Once you've created the macro, choose it from the On Exit dropdown list for the Checkbox properties.
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top