My question is
Suppose I have a Column “fname” whose value is ‘Nikhil’ in table “profile”.
How to retrieve column value of sql server table and store it in label.Text of c# ASP.Net.
I mean what should be the code if I want label text to be “fname” value that is “Nikhil”
Connection is already done properly because I am able to display table data in Gridview
but not able to display it in label.
I had also seached but not understood the answer
label1.Text = ?; // I want fname here
Regards,
Nikhil
Note that Your query needs to be whatever it is to get the proper name