ProblemAccessing Controls inside HTMLTable created Dynamically

Discussion in 'ASP .Net Web Controls' started by Ashish Bhonkiya, Nov 3, 2003.

  1. Hi All,

    I have a situation where i need to create a table
    dynamically based on the number of records in the dataset.

    now my problem is not in creating the table but i have a
    Label1 Control with value Label1.Text = "MyLabelsValue"
    on the page
    when i am creating the rows in htmltable i need to add
    this Label1 to first row first column of the table till
    now i am able to do this.

    but when i submit the page and then try to access the
    value of the Label1 value disappers.

    is it beacuse i am doing Table1.Rows[0].Cells
    [0].Controls.Add(Label1); and when i post the form back i
    dont get this LabelControl beac its now a part of
    HTMLTable ?

    AnyIdeas will be of great help
    Thanks a Lot to all in advance.

    Regards
    Ashish Bhonkiya
    Ashish Bhonkiya, Nov 3, 2003
    #1
    1. Advertising

Want to reply to this thread or ask your own question?

It takes just 2 minutes to sign up (and it's free!). Just click the sign up button to choose a username and then you can ask your own questions on the forum.
Similar Threads
  1. Rick Spiewak
    Replies:
    3
    Views:
    5,024
  2. Raed Sawalha
    Replies:
    2
    Views:
    1,507
    =?Utf-8?B?UHN5Y2hv?=
    Oct 5, 2004
  3. Jose Walker
    Replies:
    0
    Views:
    444
    Jose Walker
    Jul 11, 2006
  4. msimmons
    Replies:
    0
    Views:
    454
    msimmons
    Jul 16, 2009
  5. Ashish Bhonkiya

    Problem Creating Dynamic HTMLTable and Accessing Controls inside it

    Ashish Bhonkiya, Nov 1, 2003, in forum: ASP .Net Web Controls
    Replies:
    0
    Views:
    108
    Ashish Bhonkiya
    Nov 1, 2003
Loading...

Share This Page