Home » Questions » Computers [ Ask a new question ]

Is there a way to link text controls in Word 2007?

Is there a way to link text controls in Word 2007?

I am creating a form in Word 2007, using the controls available in the Developer tab.

Asked by: Guest | Views: 223
Total answers/comments: 1
Guest [Entry]

"You can do it using VBA:

Give each textbox a name (in Design mode, right-click each of them and get properties and fill in the Name property)
Right click the first text box and choose View Code
Add the code at the bottom of this answer into the VBA editor (assuming you called the page 1 textbox Box1 and the page 2 textobx Box2)

Exit design mode and then type something into the textbox on page 1. You should see that the textbox on page2 has the same value.

Note that people who open the form have to have their security settings set to enable the running of macros for this to work.

Private Sub Box1_Change()
Box2.Value = Box1.Value
End Sub"