Is there a better way to access controls in an ITemplate than FindControl ()?

When a control is added to the UpdatePanel, it can still be obtained from the code located behind the containing page. How is this achieved? Can user control developers do the same?

In other words, if I create a template control using the ITemplate interface, there is a way to connect it (for example, UpdatePanel), so that any controls contained inside (declaratively) can be accessed from the contained page as well

+5
source share
1 answer

TemplateInstanceAttribute ITemplate, , :

[TemplateInstance(TemplateInstance.Single)]
public ITemplate AnonymousTemplate {
  get { ... }
  set { ... }
}

MSDN:

TemplateInstanceAttribute , . , , , . ZoneTemplate , .

+7

All Articles