A Microsoft Office (Excel, Word) forum. OfficeFrustration

If this is your first visit, be sure to check out the FAQ by clicking the link above. You may have to register before you can post: click the register link above to proceed. To start viewing messages, select the forum that you want to visit from the selection below.

Go Back   Home » OfficeFrustration forum » Microsoft Access » Using Forms
Site Map Home Register Authors List Search Today's Posts Mark Forums Read  

Selecting option from a drop down menu and populating form



 
 
Thread Tools Display Modes
  #1  
Old May 28th, 2004, 11:36 AM
carolm
external usenet poster
 
Posts: n/a
Default Selecting option from a drop down menu and populating form

Hi All

This question has probably been asked a million times before but....

I have a form that i have a can select a course ID No from eg. WORD001 from a combo box. I would like to be able to select this option and have a field where the CourseDescription would update itself with the relevant course.

For some reason i have set up the Course Description as a combo box when setting up the tables so at the minute i have to select the relevant course from a drop down box.

I'm not entirely sure how i can change it so that when i select the course no the description will self populate.

Any help would be appreciated

Thanks

Carolm
  #2  
Old May 28th, 2004, 01:36 PM
Cheryl Fischer
external usenet poster
 
Posts: n/a
Default Selecting option from a drop down menu and populating form

Here is a KB link that should be helpful to you:

ACC2000: How to Populate Text Boxes with Multicolumn Combo Box Selections
http://support.microsoft.com/default...2900#appliesto

If you are using Access 97 or 2002, this article contains links to using
this technique with those versions.

--

Cheryl Fischer, MVP Microsoft Access



"carolm" wrote in message
...
Hi All

This question has probably been asked a million times before but....

I have a form that i have a can select a course ID No from eg. WORD001

from a combo box. I would like to be able to select this option and have a
field where the CourseDescription would update itself with the relevant
course.

For some reason i have set up the Course Description as a combo box when

setting up the tables so at the minute i have to select the relevant course
from a drop down box.

I'm not entirely sure how i can change it so that when i select the course

no the description will self populate.

Any help would be appreciated

Thanks

Carolm



  #3  
Old May 28th, 2004, 01:45 PM
Jeff Boyce
external usenet poster
 
Posts: n/a
Default Selecting option from a drop down menu and populating form

Carolm

If I understand what you are trying to do, you'd like a control (field) on
your form to display the course description of a course you select in a
combo box.

If so, first be sure your combo box source includes the course description
as one of its fields. Then, one approach would be to add code in the combo
box's AfterUpdate event that "sets" the value of a textbox control (unbound)
that you've added to your form. The code looks something like (actual
syntax may vary):

Me!MyTextBox = Me!MyComboBox.Column(n)

where "n" is the number of the column from the combo box in which "course
description" shows up. NOTE: the Column(n) feature counts starting at
zero, so if "course description" is the third physical column in your query,
you'd use .Column(2).

Good luck

Jeff Boyce
Access MVP

 




Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is Off
HTML code is Off
Forum Jump


All times are GMT +1. The time now is 05:29 PM.


Powered by vBulletin® Version 3.6.4
Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
Copyright ©2004-2024 OfficeFrustration.
The comments are property of their posters.