Member Avatar

Can anyone help me to display the data retrieved from SQL server in text area of html in C#

Are you returning just one record from the database or a dataset?
If one record you can place it into the text area using its .Text method (your text area is marked as runat="server" right?). E.g. textArea.Text = dataString;

assuming you returned a string from the database a sample might look like this:

string data = command.ExecuteScalar().ToString();
textArea.Text = data // you can of course do this in one line if you prefer

Returning a dataset is a little bit harder as you need to loop through the rows and concatenate them together for display in the text box.