+1 Glenn Walker · March 26, 2015
I have a form that contains a combobox (actually several).  What I want to do have a combo box that has a selection list that has the contents of one field from a table and places the contents of another field in that same table into a field in another table  It would work as follows:

Table1 = lkpMBDept

    FieldA = strDeptID (String field consists of one character.  Alphanumeric)
    FieldB = strDept (String field 125 characters consisting of department name)

Table2 = setMBItemNumber

    FieldA = strDepartment (String field consisting of 1 character. Alphanumeric)

What I want to do is to have Table1.FieldB display as the list to select from.
I then want to input the value of Table1.FieldA to be input into Table2.FieldA

I have attempted about every combination of properties in the combobox properties that I can think of and have been unable to achieve this.  I attempted to attach a screen shot of the properties, but get an error http 302. (both as jpg and gif).

So here are the properties of the combobox properties I have been working with (just one of many variations I have tried)  And this one doesn't work either:

Under Data:
      Advanced: None
      SelectedItem: BindingSource Table1.FieldB
      SelectedValue: BindingSource Table2.FieldA
      Tag: None
      Text: None
DataSource: BindingSource Table2
DisplayMember: Table1.FieldB
Tag: none
ValueMember: Table1.FieldA

The properties above are the only ones I have been working with for using this combo box.

Would appreciate any help with this.

Post a Reply


Oldest  Newest  Rating
0 Glenn Walker · April 1, 2015
Good question.  The reason is, is that I want the user to have a fixed set of inputs for those fields in a datatable.  The comboboxes each have a table that is their datasource.  Each of those tables have a fixed set of inputs, particular to the combobox.  What is being built here is a smart number (alphaneumeric).  The first field is one character and requires either a single number or a letter.  What is presented in the combobox is a set of names (in this case let's say they are departments in a company.  Each one of those names has a number or letter associated with it such that when the user selects one of those names the associated number is placed into the field. and so on for each part of the number that is smart.  You would end up with something like this:
1J035A0001, with the first one having having meaning, the J0 having meaning, 35 having meaning and A having meaning, with all the rest being an ascention number.

  I did finally get it figured out on how the properties need to be set to pull this off, if you are interested.
0 James Juan · March 28, 2015
, .sir, why dont you just use code to populate and save data in your 2nd table instead of using combobox properties to set it?
  • 1

Visual Basic


One of the first products to provide a graphical environment and a paint metaphor for developing user interfaces.

Bucky Roberts Administrator