PDA

View Full Version : [CLOSED] UserControlLoader : ID vs UserControlID



cwolcott
Oct 01, 2012, 4:38 PM
What is the difference between the attributes UserControlId vs Id? Why use one over the other? Or should both be used?

While working on the thread "Calling UserControl Methods from parent form (Javascript)" (http://forums.ext.net/showthread.php?21240-CLOSED-Calling-UserControl-Methods-from-parent-form-(Javascript)&p=91730&viewfull=1#post91730) I inadvertantly assigned both ID and UserControlId to the same value. This caused several issues. Once I found my issue I tried to understand which one I should use and how to use it.

Daniil
Oct 01, 2012, 6:38 PM
Hi Chris,

As far as I know all page controls in ASP.NET should have unique ID.

When you set the same ID and UserControlID for the UserControlLoader you get two controls with the same ID - the UserControlLoader and the user control.

cwolcott
Oct 01, 2012, 6:42 PM
It took me a couple of times saying it out loud, instead of in my head, to understand that the ID attribute is associated with the UserControlLoader and the UserControlId attribute is associated with the user control. I got it!!

Please close the thread.

Daniil
Oct 01, 2012, 6:57 PM
:)

By the way, could you clarify why do not you update Chrome? There is 22 already.

cwolcott
Oct 01, 2012, 9:35 PM
:)

By the way, could you clarify why do not you update Chrome? There is 22 already.

Our development system is on a standalone network and I hadn't thought about grabbing a new version of Chrome. Thanks for the heads up. Just downloaded the offline version and will bring it to work tomorrow [Version 22.0.1229.79 m]