Home |
Search |
Today's Posts |
#1
Posted to microsoft.public.word.docmanagement
|
|||
|
|||
Auto populate a field?
I want to be able to have users select their employer from say a drop-down
list, then once either of the employers is selected, their address shows up on the next line. I made an attempt at an 'if' statement, but it was way too long and the formula bar wouldn't accept it. I want to do this to avoid having to use two different forms depending on which employer they work for. Select employer, auto complete the address for them...easy. Or is it?? LOL!! I have no idea when it comes to programming, and it seems anything I knew about macros has also been lost soemwhere along my journey from school to being almost 40 |
#2
Posted to microsoft.public.word.docmanagement
|
|||
|
|||
Auto populate a field?
The following can be used to set the value of another formfield based on the
item selected from the drop down in such a form ' Macro created 15-11-97 by Doug Robbins to add the address corresponding to a drop down name ' Set myDrop = ActiveDocument.FormFields("Dropdown1").DropDown Company = myDrop.ListEntries(myDrop.Value).Name Address = ActiveDocument.AttachedTemplate.AutoTextEntries(Co mpany).Value ActiveDocument.FormFields("Text1").Result = Address -- 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 "gotta question" wrote in message ... I want to be able to have users select their employer from say a drop-down list, then once either of the employers is selected, their address shows up on the next line. I made an attempt at an 'if' statement, but it was way too long and the formula bar wouldn't accept it. I want to do this to avoid having to use two different forms depending on which employer they work for. Select employer, auto complete the address for them...easy. Or is it?? LOL!! I have no idea when it comes to programming, and it seems anything I knew about macros has also been lost soemwhere along my journey from school to being almost 40 |
#3
Posted to microsoft.public.word.docmanagement
|
|||
|
|||
Auto populate a field?
So would I insert a field and somehow paste that macro in there? I haven't
attempted a macro since wordperfect Also, is there a way to get he document to not warn against macros, so users can't disable them? (In relation to having to add this macro to it). I hope you're still 'listening'! You sound like you know your siht!! "Doug Robbins - Word MVP" wrote: The following can be used to set the value of another formfield based on the item selected from the drop down in such a form ' Macro created 15-11-97 by Doug Robbins to add the address corresponding to a drop down name ' Set myDrop = ActiveDocument.FormFields("Dropdown1").DropDown Company = myDrop.ListEntries(myDrop.Value).Name Address = ActiveDocument.AttachedTemplate.AutoTextEntries(Co mpany).Value ActiveDocument.FormFields("Text1").Result = Address -- 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 "gotta question" wrote in message ... I want to be able to have users select their employer from say a drop-down list, then once either of the employers is selected, their address shows up on the next line. I made an attempt at an 'if' statement, but it was way too long and the formula bar wouldn't accept it. I want to do this to avoid having to use two different forms depending on which employer they work for. Select employer, auto complete the address for them...easy. Or is it?? LOL!! I have no idea when it comes to programming, and it seems anything I knew about macros has also been lost soemwhere along my journey from school to being almost 40 |
#4
Posted to microsoft.public.word.docmanagement
|
|||
|
|||
Auto populate a field?
No. See http://www.gmayor.com/installing_macro.htm
-- Suzanne S. Barnhill Microsoft MVP (Word) Words into Type Fairhope, Alabama USA Word MVP FAQ site: http://word.mvps.org Email cannot be acknowledged; please post all follow-ups to the newsgroup so all may benefit. "gotta question" wrote in message ... So would I insert a field and somehow paste that macro in there? I haven't attempted a macro since wordperfect Also, is there a way to get he document to not warn against macros, so users can't disable them? (In relation to having to add this macro to it). I hope you're still 'listening'! You sound like you know your siht!! "Doug Robbins - Word MVP" wrote: The following can be used to set the value of another formfield based on the item selected from the drop down in such a form ' Macro created 15-11-97 by Doug Robbins to add the address corresponding to a drop down name ' Set myDrop = ActiveDocument.FormFields("Dropdown1").DropDown Company = myDrop.ListEntries(myDrop.Value).Name Address = ActiveDocument.AttachedTemplate.AutoTextEntries(Co mpany).Value ActiveDocument.FormFields("Text1").Result = Address -- 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 "gotta question" wrote in message ... I want to be able to have users select their employer from say a drop-down list, then once either of the employers is selected, their address shows up on the next line. I made an attempt at an 'if' statement, but it was way too long and the formula bar wouldn't accept it. I want to do this to avoid having to use two different forms depending on which employer they work for. Select employer, auto complete the address for them...easy. Or is it?? LOL!! I have no idea when it comes to programming, and it seems anything I knew about macros has also been lost soemwhere along my journey from school to being almost 40 |
Reply |
Thread Tools | |
Display Modes | |
|
|
Similar Threads | ||||
Thread | Forum | |||
auto copy text in word to another text field in word | New Users | |||
How do you turn off auto update of date field | New Users | |||
Auto update field problem | Microsoft Word Help | |||
Auto fill a form field | Microsoft Word Help | |||
Auto Jump Text Field to Text Field | Tables |