|
-
Oct 14th, 2002, 06:02 AM
#1
Thread Starter
Fanatic Member
More combo problems
I have a combo on my form whos purpose is to allow users to search the form. The combo displays "itemDescription" but holds "itemID" as Valuemember.
I have populated a combobox with the following:
daCombo.FillSchema(dsCombo, SchemaType.Source, "tblItems")
'fiLLDATASET WITH INFO FROM DATAADAPTOR
daCombo.Fill(dsCombo, "tblItems")
'empty combo box
ComboBox2.Items.Clear()
'fill combobox2
ComboBox2.DataSource = dsCombo.Tables("tblitems")
ComboBox2.DisplayMember = "itemDescription"
ComboBox2.ValueMember = "itemID"
I then use the following line of code:
objROw = objdataset.Tables("tblItems").Rows.Find(ComboBox2.SelectedItem.ToString)
Which throws up this error:
"Additional information: Input string was not in a correct format."
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
|