harish main

harish main

  • NA
  • 10
  • 0

TextBox and Repeater does not work when used together in C#

Mar 14 2011 4:09 PM
I was using Repeater in c# and it was able to display all the data, recently i added Multiline TextBox and after that the Repeater value is not getting displayed. But if i comment TextBoxLogInfo then the Repeater display all the data.

Is there way to show data for both same time.

Code in c#
------------
SqlDataReader sdr = cmd.ExecuteReader();
while (sdr.Read())
{
   //Assign to your textbox here  
   TextBoxLogInfo.Text = sdr["LOG_DETAILS"].ToString();               
}

//DataBinding Repeater
Repeater1.DataSource = sdr;
Repeater1.DataBind();

Your help will be highly appreciated

Thanks

Answers (4)