|
-
March 23rd, 2004, 08:17 AM
#1
Multiple combos on one DataAdapter
I'm creating a data-driven Windows Form dialog which has two combo boxes both of which are lookups to the same table: one is HomeNationID, the other CurrentNationID looking up the Nation (NationID, Description) table.
I have set both combos to have their DataSource as my Nation table with DisplayMember as Nation.Description and ValueMember as Nation.NationID.
When I Show the form I get a runtime error Error creating window handle. (an OutOfMemoryException), it's InnerException is Object reference not set to an instance of an object., the stack trace goes back through ComboBox.SetItemsCore, ListControl.DataManager_ItemChanged and Forms.Control.UpdateBindings (with some others in between).
I can't add the Nation table a second time to the DataSet (not allowed two tables with the same name).
This doesn't seem like a particularly odd requirement - two combos with the same lookup table.
PeteB
I wouldn't say "he's not the smartest knife,"
I'd say "he's a spoon."
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|