Solved

Drop down list

Posted on 2013-06-16
10
400 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
Salesforce Made Easy to Use

On-screen guidance at the moment of need enables you & your employees to focus on the core, you can now boost your adoption rates swiftly and simply with one easy tool.

 
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

Three Reasons Why Backup is Strategic

Backup is strategic to your business because your data is strategic to your business. Without backup, your business will fail. This white paper explains why it is vital for you to design and immediately execute a backup strategy to protect 100 percent of your data.

Question has a verified solution.

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

Preparing an email is something we should all take special care with – especially when the email is for somebody you may not know very well. The pressures of everyday working life stacked with a hectic office environment can make this a real challen…
The Windows Phone Theme Colours is a tight, powerful, and well balanced palette. This tiny Access application makes it a snap to select and pick a value. And it doubles as an intro to implementing WithEvents, one of Access' hidden gems.
In Microsoft Access, learn how to use Dlookup and other domain aggregate functions and one method of specifying a string value within a string. Specify the first argument, which is the expression to be returned: Specify the second argument, which …
With Microsoft Access, learn how to start a database in different ways and produce different start-up actions allowing you to use a single database to perform multiple tasks. Specify a start-up form through options: Specify an Autoexec macro: Us…

626 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