Using Form Filed to populate form

  • Thread starter Thread starter Guest
  • Start date Start date
G

Guest

I am creating a form. They want the user to select a branch name and have the
branch's address filled in. Is there a way to do this? I have entered the
branches & branch addresses in an Access database. There is a VB programmer
on staff, but he has not worked with MS Word b/4. We are usng MS Word 2003.
 
Hi DJElliott,

If you use a DropDown field for the branch names and set the field's properties to 'Calculate on Exit', you could then use a series
if IF fields combined with REF fields to output the addresses.

For example, say the DropDown field's name is 'DropDown1' and it's populated with 'Branch1', 'Branch2', 'Branch3', etc. Then you
could get the addresses to generate automatically with a series of fields coded as:
{IF{REF DropDown1}= "Branch1" "Branch1 Address"}
{IF{REF DropDown1}= "Branch2" "Branch2 Address"}
{IF{REF DropDown1}= "Branch3" "Branch3 Address"}
etc.

Note: the field braces shown above are created in pairs via Ctrl-F9 - you can't simply copy them from the above. Plus, you'll have
to protect the document for forms before anything will work.

Cheers
 
Headin' down the hall to the VB programmer

thanks!
--
DJELLIOTT


macropod said:
Hi DJElliott,

If you use a DropDown field for the branch names and set the field's properties to 'Calculate on Exit', you could then use a series
if IF fields combined with REF fields to output the addresses.

For example, say the DropDown field's name is 'DropDown1' and it's populated with 'Branch1', 'Branch2', 'Branch3', etc. Then you
could get the addresses to generate automatically with a series of fields coded as:
{IF{REF DropDown1}= "Branch1" "Branch1 Address"}
{IF{REF DropDown1}= "Branch2" "Branch2 Address"}
{IF{REF DropDown1}= "Branch3" "Branch3 Address"}
etc.

Note: the field braces shown above are created in pairs via Ctrl-F9 - you can't simply copy them from the above. Plus, you'll have
to protect the document for forms before anything will work.

Cheers
--
macropod
[MVP - Microsoft Word]
-------------------------

DJElliott said:
I am creating a form. They want the user to select a branch name and have the
branch's address filled in. Is there a way to do this? I have entered the
branches & branch addresses in an Access database. There is a VB programmer
on staff, but he has not worked with MS Word b/4. We are usng MS Word 2003.
 
Hi DJElliott,

Um, there's no vba in this - it's just Word fields.

Cheers
--
macropod
[MVP - Microsoft Word]
-------------------------

DJElliott said:
Headin' down the hall to the VB programmer

thanks!
--
DJELLIOTT


macropod said:
Hi DJElliott,

If you use a DropDown field for the branch names and set the field's properties to 'Calculate on Exit', you could then use a
series
if IF fields combined with REF fields to output the addresses.

For example, say the DropDown field's name is 'DropDown1' and it's populated with 'Branch1', 'Branch2', 'Branch3', etc. Then you
could get the addresses to generate automatically with a series of fields coded as:
{IF{REF DropDown1}= "Branch1" "Branch1 Address"}
{IF{REF DropDown1}= "Branch2" "Branch2 Address"}
{IF{REF DropDown1}= "Branch3" "Branch3 Address"}
etc.

Note: the field braces shown above are created in pairs via Ctrl-F9 - you can't simply copy them from the above. Plus, you'll
have
to protect the document for forms before anything will work.

Cheers
--
macropod
[MVP - Microsoft Word]
-------------------------

DJElliott said:
I am creating a form. They want the user to select a branch name and have the
branch's address filled in. Is there a way to do this? I have entered the
branches & branch addresses in an Access database. There is a VB programmer
on staff, but he has not worked with MS Word b/4. We are usng MS Word 2003.
 
Back
Top