Getting id of composite child controls

Discussion in 'ASP .Net Building Controls' started by Chris Kennedy, Jun 14, 2004.

  1. I can't seem to get the id of the child controls of my composite control. I
    can get the unique id but the id when I try to access it via the controls
    collection comes back null. Do I need to add a form tag within the control
    rather than on aspx parent page. Any ideas? Regards, Chris.
     
    Chris Kennedy, Jun 14, 2004
    #1
    1. Advertising

  2. Chris Kennedy

    Zafar Iqbal Guest

    Chris Kennedy used his keyboard to write :
    > I can't seem to get the id of the child controls of my composite control. I
    > can get the unique id but the id when I try to access it via the controls
    > collection comes back null. Do I need to add a form tag within the control
    > rather than on aspx parent page. Any ideas? Regards, Chris.


    If you are making a composite control, which will have other child
    control in it, then you need to implement INamingContainer interface.
    This interface provide the facility to properly provide ids to the
    child controls according to the heirarchical rules used by ASP.NET

    Regards
    Zafar Iqbal

    --
    This is an automatic signature of MesNews.
    Site : http://mesnews.no-ip.com
     
    Zafar Iqbal, Jun 16, 2004
    #2
    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. sleigh
    Replies:
    1
    Views:
    2,705
    sleigh
    Feb 12, 2004
  2. Jeff Rodriguez
    Replies:
    23
    Views:
    1,158
    David Schwartz
    Dec 9, 2003
  3. Replies:
    0
    Views:
    216
  4. David Boike

    Child controls in Composite Controls not firing events

    David Boike, Aug 7, 2003, in forum: ASP .Net Web Controls
    Replies:
    0
    Views:
    322
    David Boike
    Aug 7, 2003
  5. Mike

    Composite vs non composite Controls

    Mike, Mar 10, 2005, in forum: ASP .Net Web Controls
    Replies:
    4
    Views:
    272
    Sundararajan
    Mar 11, 2005
Loading...

Share This Page