Reply
 
Thread Tools Display Modes
  #1   Report Post  
kimee11972
 
Posts: n/a
Default forms help - drop down boxes

I've created a form and am having trouble getting the drop-down boxes to
behave like I want them too.

The user of the form should select an item from the drop down box, but I
want the result to be a code for the item. So, for example, if the user
chooses the item "black," once he/she tabs out of the field, the code "blk"
should populate that field. This will be true of most of the drop down boxes
in my form. I do not want to use the code itself in the drop down list,
because in most cases, the correlation will not be this simple.

I've tried a macro to accomplish this, and though the behavior is correct,
once the user moves out of the field, the result code (i.e. "blk") is added
to the list of available items in the drop down box.

Any ideas?
  #2   Report Post  
Doug Robbins
 
Posts: n/a
Default

You did not show us the code for the macro that you are using, but there is
a problem with this sort of thing which is, what happens if the user needs
to change their selection? Can you live with a separate textbox being
populated with the code corresponding to the item selected in the DropDown
formfield?

Maybe you should be using a UserForm with a two column combobox or listbox
in it and then have the document populated with whatever it needs to be when
the user clicks on a command button on the form.

See the article "How to create a Userform" at:

http://word.mvps.org/FAQs/Userforms/CreateAUserForm.htm


--
Please respond to the Newsgroup for the benefit of others who may be
interested. Questions sent directly to me will only be answered on a paid
consulting basis.

Hope this helps,
Doug Robbins - Word MVP
"kimee11972" wrote in message
...
I've created a form and am having trouble getting the drop-down boxes to
behave like I want them too.

The user of the form should select an item from the drop down box, but I
want the result to be a code for the item. So, for example, if the user
chooses the item "black," once he/she tabs out of the field, the code
"blk"
should populate that field. This will be true of most of the drop down
boxes
in my form. I do not want to use the code itself in the drop down list,
because in most cases, the correlation will not be this simple.

I've tried a macro to accomplish this, and though the behavior is correct,
once the user moves out of the field, the result code (i.e. "blk") is
added
to the list of available items in the drop down box.

Any ideas?



Reply
Thread Tools
Display Modes

Posting Rules

Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
how to create check mark boxes Cindy N Page Layout 2 March 3rd 05 07:39 PM
Drop down boxes in forms Cindy Microsoft Word Help 2 January 26th 05 10:57 PM
Excel worksheet in Word linked text boxes Eduardo Oliveira Page Layout 0 January 5th 05 11:23 PM
Word & Drop Down Menu's starkman Microsoft Word Help 1 January 2nd 05 10:39 PM
Creating forms; drop down lists harry Microsoft Word Help 1 December 8th 04 06:45 PM


All times are GMT +1. The time now is 10:45 PM.

Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
Copyright ©2004-2024 Microsoft Office Word Forum - WordBanter.
The comments are property of their posters.
 

About Us

"It's about Microsoft Word"