Home Answers Viewqa HTML How to display gridview details to labels dynamically?

 
 


KoolSteel
How to display gridview details to labels dynamically?
1 Answer(s)      a year and a month ago
Posted in : HTML

I am using SQLDataSource to connect to MySQL. I have a gridview that retrieves information from MySQL database based on a selected id(dropdownlist). I need to display the gridview results on labels. I used lbDate.Text = GridView1.Rows(0).Cells(0).Text to display however, it always displays the details of the previously selected id. Which means it displays the information wrong information. What I understand is that it does the page load method( lbDate.Text = GridView1.Rows(0).Cells(0).Text) before it retrieves the new information, that's why it always shows the previous info. Can anyone help me. Thanks

View Answers

April 17, 2012 at 3:19 PM










Related Pages:

Ask Questions?

If you are facing any programming issue, such as compilation errors or not able to find the code you are looking for.

Ask your questions, our development team will try to give answers to your questions.