selecting records for 2nd combo box dependant on first combo box 
Author Message
 selecting records for 2nd combo box dependant on first combo box

I'm using VB 6.0. I have a form with 2 combo boxes, both get there"fill"
from two different MS Access table's. I only want to load some of the
records in the second combo box, depending on what was selected at run
time in the first combo box. Do I need two forms to do this or is there
any easier way? I am very new at VB. Thanks for your time.
Brian


Mon, 06 Aug 2001 03:00:00 GMT  
 selecting records for 2nd combo box dependant on first combo box
On Thu, 18 Feb 1999 09:11:31 -0500, "Brian J. McNamara"

Quote:

>I'm using VB 6.0. I have a form with 2 combo boxes, both get there"fill"
>from two different MS Access table's. I only want to load some of the
>records in the second combo box, depending on what was selected at run
>time in the first combo box. Do I need two forms to do this or is there
>any easier way? I am very new at VB. Thanks for your time.
>Brian

This should give you an idea of where to start...if you need more mail
me as I have code specifically for this, but will have to dig it
out....

To use the "SelectedItem" property of the dbCombo the following code
is placed in the click event of dbcName.

        Data1.Recordset.Bookmark = dbcName.SelectedItem 'move to the
selected
record in data control
        strPlayerID = Data1.Recordset("PlayerID")

    Dim pqdPersonal As QueryDef
    Set pqdPersonal = dbData.QueryDefs("qryPFill")    'This is a
stored
Parameter query
    pqdPersonal("varPlayerID") = strPlayerID
    Set rsPersonal = pqdPersonal.OpenRecordset()

HTH,
Ed Phillippe

****************************************
NOTICE TO BULK EMAILER(S):
Pursuant to US Code, Title 47, Chapter
5, Subchapter II, 227, any & all
unsolicited commercial e-mail sent to
this address is subject to a download
and archival fee in the amount of
$500 US and copies will be forwarded
to domain administrators--E-mailing
denotes acceptance of said terms!

BUT, just in case you do SPAM this:





****************************************



Thu, 09 Aug 2001 03:00:00 GMT  
 
 [ 2 post ] 

 Relevant Pages 

1. load 2nd combo box - depend on first combo box

2. Help filling second combo box from first combo box

3. Cetting A Report To Select Records Based Upon A Value Selected In A Combo Box

4. enter data in a combo box based on value from another combo box

5. Limit subform combo box by selection in parent combo box

6. Want Access combo box to filter rowsource of another combo box

7. Populating a combo box from another combo box

8. Populate a combo box from another combo box selection

9. Help filling second combo box from fist combo box

10. Combo box selection narrows next combo box choices

11. Setting Combo box ListIndex initiates Combo box Click event

12. combo box/database combo box vlaue question - newbie

 

 
Powered by phpBB® Forum Software