Solved

Drop down list

Posted on 2013-06-16
10
393 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
  • 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
 
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
How to run any project with ease

Manage projects of all sizes how you want. Great for personal to-do lists, project milestones, team priorities and launch plans.
- Combine task lists, docs, spreadsheets, and chat in one
- View and edit from mobile/offline
- Cut down on emails

 
LVL 119

Expert Comment

by:Rey Obrero
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

IT, Stop Being Called Into Every Meeting

Highfive is so simple that setting up every meeting room takes just minutes and every employee will be able to start or join a call from any room with ease. Never be called into a meeting just to get it started again. This is how video conferencing should work!

Join & Write a Comment

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…
Overview: This article:       (a) explains one principle method to cross-reference invoice items in Quickbooks®       (b) explores the reasons one might need to cross-reference invoice items       (c) provides a sample process for creating a M…
Learn how to number pages in an Access report over each group. Activate two pass printing by referencing the pages property: Add code to the Page Footers OnFormat event to capture the pages as there occur for each group. Use the pages property to …
Polish reports in Access so they look terrific. Take yourself to another level. Equations, Back Color, Alternate Back Color. Write easy VBA Code. Tighten space to use less pages. Launch report from a menu, considering criteria only when it is filled…

707 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

Need Help in Real-Time?

Connect with top rated Experts

16 Experts available now in Live!

Get 1:1 Help Now