One Listbox showing all cities. If you select one city in
list box the information related to that particular city
should be displayed in Datagrid . How do you do that?

Answer Posted / sathish

On select change event of the list box use the following code.

Dim con as new sqlconn("connectionstring")
con.open()
dim da as sqlda("select * from table where cityname=" &
listbox1.selecteditem)
dim ds as new dataset
da.fill(ds)

Is This Answer Correct ?    5 Yes 1 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

Is there any property names “isnavigating”?

581


What is state management in asp.net with example?

464


What is a session in programming?

558


How to add DateTime Control in normal DataGrid Server Control?

584


What is enableviewstate in asp net?

527






Explain the updatepanel?

584


What are the advantages of asp.net?

543


What is the concept of view state in asp.net?

565


Do cookies store passwords?

505


Is it possible to change the index of primary key on table?

410


What is the use of web.config file?

535


Name the two properties are on every validation control?

547


What is the significance of proxy user?

619


How can we create pie chart in asp.net?

589


What is clr? Difference between clr & cts?

688