Hi
i want to display state name in combobox and theri values should be id's and these value i get on second page can any one help me how can i do this in silverlight.................?
Loading
Know the answer? Post it — somebody with the same question will find it here.
Sign in to answer this question
It is the same account you read, post and publish with — and you will come straight back to this page.
Hemant KumarPosted Oct 27, 2011, 10:47 AM
Suthish NairPosted Oct 27, 2011, 2:14 PM
Smart LuckyPosted Oct 27, 2011, 7:47 AM
I want just Static .............not form database..
Hemant KumarPosted Oct 27, 2011, 1:39 AM
private void buildcboAuthors()
{
OleDbCommand cmd = new OleDbCommand("SELECT * FROM tblAuthors",conn);
this.conn .Open ();
OleDbDataReader rsAutors = cmd.ExecuteReader();
ArrayList Authors = new ArrayList();
while(rsAutors.Read())
{
Authors.Add (new AddValue
(rsAutors.GetString(1),rsAutors.GetInt32 (0)));
}
rsAutors.Close();
this.conn.Close();
this.cboAuthors.DataSource = Authors;
this.cboAuthors .DisplayMember ="Display";
this.cboAuthors.ValueMember = "Value";
AuthorsHaveBeenAdded=true;
}