Results 1 to 2 of 2
  1. #1
    New Lounger
    Join Date
    Sep 2002
    Location
    St. Paul, Minnesota, USA
    Posts
    18
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Hopefully a really simple Combo Box question (97)

    This should be pretty simple, but I can't figure it out, so here goes:
    I have a table of subscription types that are coded (the code field is TypeID). I want to put a combo box on the form to limit the selection to the available types, and I want the text displayed in the field. However, when the user selects the Type, I want the correct TypeID to be populated in the TypeID field in the School table. Since the user doesn't really need to know what the TypeID is, I don't want it displayed anywhere.

    I've not worked with VB very much, but I'm guessing that if it is required, it's a fairly simply x=y expression, and I just don't know how to tell it which table I want to populate the appropriate field in. So if that's the case, a real basic example is all I'd need.

    The real kicker is that I want to do this very same thing in four different places, and this will go a long way to finishing my form.

    I tried looking through the help files, but they didn't seem to cover this rather obvious thing to want to do.

  2. #2
    New Lounger
    Join Date
    Jul 2002
    Posts
    10
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Re: Hopefully a really simple Combo Box question (97)

    If I'm reading you right it is simplea and doesn't need code. On your form put a combo box using the wizard, select the option that says look up values in table or qry. Look up from your type table selecting both the type and ID fields but then chose the option to hide the key (ID field). If for some reason you can't do that then in the properties section for the combo box go to column widths and put a 0" for the ID column so it will look like 0";1" if the ID is the key field it will be saved and the typt text will be displayed.

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •