Want to win a PS4? Go Premium and enter to win our High-Tech Treats giveaway. Enter to Win

x
?
Solved

Text Box Auto Copy to Another

Posted on 2006-06-21
1
Medium Priority
?
366 Views
Last Modified: 2008-02-01
Hello,

I am having trouble figuring out how a Word macro/subroutine/or other method can copy a value from one text box filled in on a form to another text box on same form.

I need the user to fill in his name on page one of a form and then have that name apear in another text box on page two automaticaly.

I have Googled this to death, but to no avail.

Thanks in advance.

0
Comment
Question by:kchrisc
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
1 Comment
 
LVL 76

Accepted Solution

by:
GrahamSkan earned 400 total points
ID: 16955923
Since you mention a form, I presume that you are talking about text form fields, as opposed to a text box from the Insert menu.

This macro will copy from one text form field (Text1) to another (Text2).

Sub CopyTextBox()
    ActiveDocument.FormFields("Text2").Result = ActiveDocument.FormFields("Text1").Result
End Sub

Create the macro, then make it the Exit macro in the first form field.


Note that if there is no need to edit the repeated information, you could replace the second field with a Ref field using the name of the first form field. If you display the field codes, it will look like this.

{ Ref Text1 }

Tick 'Calculate on exit' in the form field's options(properties) window to ensure that the Ref field is updated immediately.
0

Featured Post

Ask an Anonymous Question!

Don't feel intimidated by what you don't know. Ask your question anonymously. It's easy! Learn more and upgrade.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

This article describes a method of delivering Word templates for use in merging Access data to Word documents, that requires no computer knowledge on the part of the recipient -- the templates are saved in table fields, and are extracted and install…
Ever visit a website where you spotted a really cool looking Font, yet couldn't figure out which font family it belonged to, or how to get a copy of it for your own use? This article explains the process of doing exactly that, as well as showing how…
In this video, we show how to convert an image-only PDF file into a PDF Searchable Image file, that is, a file with both the image (typically from scanning) and text, which is created in an automated fashion with Optical Character Recognition (OCR) …
This video walks the viewer through the process of creating an MLA formatted document, as well as a bibliography with citations.
Suggested Courses

598 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question