المساعد الشخصي الرقمي

مشاهدة النسخة كاملة : ComboBox index Databind



C# Programming
02-03-2010, 10:53 PM
Hi!

I have a dataset colum wich values ara simple integers.

I want to create a ComboBox with some string values, and databind the dataset as an INDEX to them.

So,

dataset has 1,2,3,4

my Combobox has "myString1", "myString2" (I can popolate manually or progrmatically, but theese values are NOT provided by the dataset)

I want to databind my dataset to my combobox so that when dataset value is 2, the combobox show "myString2".

I think it should be easy... but i'm not too used to combobox neither databind

Thanks!