Multiple controls with the same ID

Discussion in 'ASP .Net Web Controls' started by shiretu, Aug 28, 2005.

  1. shiretu

    shiretu Guest

    Hi,

    I'm trying to make a WebPropertyGrid control in ASP.NET. The control
    renders itself as expected when the request is a "GET". When I make a
    POST, I get the following error:

    Multiple controls with the same ID 'TestString' were found. FindControl
    requires that controls have unique IDs.

    The architecture of my control is quite simple: using reflection I read
    the properties from an object and generate appropriate web controls for
    the user. For basic types like int,long,string,DateTime, etc I make an
    TextBox. For complex types (those who are not in the list before) I
    recursively make another WebPropertyGrid. My WebPropertyGrid structure
    is initialized in CreateChildControls overridden method. After that I
    call the base method. The CreateChildControls method works fine even
    when I receive the error message into the browser. I suspect the
    problem is in the rendering part....


    ANY input is greatly appreciated
     
    shiretu, Aug 28, 2005
    #1
    1. Advertising

  2. shiretu

    shiretu Guest

    Additional info on the subject....


    I implement INamingContainer and the control used for rendering
    DateTime type is an custom control who also implements
    INamingContainer.
    Every id in the HTML output is ok. There are no duplicates......
     
    shiretu, Aug 28, 2005
    #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. Jeff Tolman
    Replies:
    0
    Views:
    2,999
    Jeff Tolman
    Nov 4, 2003
  2. =?Utf-8?B?UHVuaXNoZXI=?=

    Need same viewstate for same page across multiple servers

    =?Utf-8?B?UHVuaXNoZXI=?=, Mar 23, 2006, in forum: ASP .Net
    Replies:
    1
    Views:
    424
    John Timney \( MVP \)
    Mar 23, 2006
  3. Replies:
    2
    Views:
    402
    =?ISO-8859-1?Q?G=F6ran_Andersson?=
    May 4, 2006
  4. Replies:
    3
    Views:
    494
    =?Utf-8?B?UGV0ZXIgQnJvbWJlcmcgW0MjIE1WUF0=?=
    May 16, 2006
  5. gabor
    Replies:
    19
    Views:
    1,146
    Steve Holden
    May 31, 2005
Loading...

Share This Page