to bind a listbox in asp.net
write the following code
lbxLeft.DataSource = SqlDS.Tables(0)
lbxLeft.DataTextField = "Id"
lbxLeft.DataValueField = "Id"
lbxLeft.DataBind()
write the following code
lbxLeft.DataSource = SqlDS.Tables(0)
lbxLeft.DataTextField = "Id"
lbxLeft.DataValueField = "Id"
lbxLeft.DataBind()
No comments:
Post a Comment