Solved

Drop down list

Posted on 2013-06-16
10
399 Views
Last Modified: 2013-06-17
Hi All

I’m using MS Access 2007.

I have a drop down list.
Code  |  Description
    1    |     yes
    2    |     No
    3    |     Unknown

In one of my forms I need the code to reflect.  This is not a problem.  In my other form I need the Description to reflect.  How do I get the second column (Description) to reflect as the value?

Thanks in advance
0
Comment
Question by:Reyesrj
[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
  • 6
  • 3
10 Comments
 
LVL 29

Expert Comment

by:IrogSinta
ID: 39251958
If you change the BoundColumn property to 2, the values uh the second column will be returned.
0
 

Author Comment

by:Reyesrj
ID: 39251983
went back to the form and removed the field and put it back.  When I went into form view the second column was reflecting.  Then I tested it and changed the selection and it went back to reflect column 1.
0
 

Author Comment

by:Reyesrj
ID: 39251985
Sorry,

I tried that already.  The bound column is showing 2.  I also set the bound column to 2 in the table.  I went back to the form and removed the field and put it back.  When I went into form view the second column was reflecting.  Then I tested it and changed the selection and it went back to reflect column 1.
0
Independent Software Vendors: We Want Your Opinion

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

 
LVL 29

Expert Comment

by:IrogSinta
ID: 39251998
I'm a bit confused by what you mean by reflecting.  If you mean the column that is returned when you refer to the combo box via code or in a query, then that would be the bound column.  Or perhaps you are just showing a single column and want the combo box to show either column 1 or column 2; if that is the case, you would set the ColumnCount property to 2 and the ColumnWidths property to 0";1"
0
 

Author Comment

by:Reyesrj
ID: 39252042
Sorry,
When I’m in from view I click on the drop down arrow.  The code and description is displayed.  If I choose “1  |  yes” the list goes away and “1” will reflect in the field box, the bound column 1.  How do I get “Yes” to reflect in the field box, bound column 2?
0
 
LVL 120

Expert Comment

by:Rey Obrero (Capricorn1)
ID: 39252052
.
0
 

Author Comment

by:Reyesrj
ID: 39252064
0
 

Author Comment

by:Reyesrj
ID: 39252067
Please see my attachment.
Thanks
0
 
LVL 29

Accepted Solution

by:
IrogSinta earned 500 total points
ID: 39252107
I'm unable to open your attachment right now. But you would just use the column property like so:
Me.NameOTextBox = Me.NameOfComboBox.Column(1)

See this link http://msdn.microsoft.com/en-us/library/office/ff834793.aspx
0
 

Author Closing Comment

by:Reyesrj
ID: 39255258
I'm new to Access but I was able to figure out that the code goes into the code builder in after update under the Event tab.  Anyhow, this was the solution I was looking for.

Thanks.
0

Featured Post

Enterprise Mobility and BYOD For Dummies

Like “For Dummies” books, you can read this in whatever order you choose and learn about mobility and BYOD; and how to put a competitive mobile infrastructure in place. Developed for SMBs and large enterprises alike, you will find helpful use cases, planning, and implementation.

Question has a verified solution.

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

In a multiple monitor setup, if you don't want to use AutoCenter to position your popup forms, you have a problem: where will they appear?  Sometimes you may have an additional problem: where the devil did they go?  If you last had a popup form open…
Phishing attempts can come in all forms, shapes and sizes. No matter how familiar you think you are with them, always remember to take extra precaution when opening an email with attachments or links.
In Microsoft Access, learn different ways of passing a string value within a string argument. Also learn what a “Type Mis-match” error is about.
In Microsoft Access, learn the trick to repeating sub-report headings at the top of each page. The problem with sub-reports and headings: Add a dummy group to the sub report using the expression =1: Set the “Repeat Section” property of the dummy…

739 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