I am creating a custom master page type control like i.e. like a datagrid but adding custom functionality to it It should be easy, but it is a part of the desired functionality to keep a paging control that is switched off and part of that control is a text box that displays the current page number and Text on the new page Etaset-appears Cloudy went redirect.
The text box I am facing is technically embedded in a control that is actually embedded in the controls controlled by the page.
page
& Nbsp; |
Display control
& nbsp; |
Paging Controls
& nbsp; |
Textbox
There is no firing event buried in all the way, even worse, postback is not being written on Javascript page (nothing on page post so far it is only a bit Actually need to be done).
I have raised quite a bit around Google now that I need to implement ININGContainer (done) and I need to add control to the control tree of the page (whether the pre_init is too late ? It's a good time to add control to a page) Event should fire, apparently but I can not find an example of best practice on this, there are very close to where people have to clamp down But it's not a button.
So can someone talk to me? A page has been added to get embedded control in embedded control in a control so that he can behave properly?
You only need INInContainer if you have more than one instance of your custom control on the same page Want to add. What does this do is enable the unique ID generation, so that you do not end up with a single ID control. I suggest that when you make your custom control, Pre_Init is not too late, it is actually considering the lifecycle. You can instantly customize custom controls and add them to live control collection in many places. I would advise you to do the Page_Init (before the viewport load) or Page_load (after the status of the scene loads). Even if you add it later into the page lifecycle then control events will increase. You can use FindControl method to subscribe to child control incidents:
MyControl myControl = Page.FindControl ("MyControl1"); Text box text box = myControl.FindControl ("TextBox1") as text box;
Comments
Post a Comment