Hello
I try to bind both displaymember and value member of a listbox to a dtataset data, but this time the displaymember witth multiple field value as follow.
....
string SSQL= "SELECT ID, Fname,LName,Init From tblEmp";
sqlDA = new SqlDataAdapter(sSQL,sqlconn);
DS = sqlDA.Fill("General");l
listbox.DisplayMember= DS.Tables[0].Columns[1].ToString() + DS.Tables[0].Columns[2].ToString();
listbox.ValueMember= DS.Tables[0].Columns[0].ToString();
listbox.datasource =DS.Table[0];
....
but the listbox display all entries with value 'System.Data.DataRowView'.
is it posible to do that, and if so How?
ANY HELP WOULD BE VERY APPRECIATED.
I try to bind both displaymember and value member of a listbox to a dtataset data, but this time the displaymember witth multiple field value as follow.
....
string SSQL= "SELECT ID, Fname,LName,Init From tblEmp";
sqlDA = new SqlDataAdapter(sSQL,sqlconn);
DS = sqlDA.Fill("General");l
listbox.DisplayMember= DS.Tables[0].Columns[1].ToString() + DS.Tables[0].Columns[2].ToString();
listbox.ValueMember= DS.Tables[0].Columns[0].ToString();
listbox.datasource =DS.Table[0];
....
but the listbox display all entries with value 'System.Data.DataRowView'.
is it posible to do that, and if so How?
ANY HELP WOULD BE VERY APPRECIATED.