Your Privacy Matters: We use our own and third-party cookies to improve your experience on our website. By continuing to use the website we understand that you accept their use. Cookie Policy
75
UltraWebTab user control, with tabs as controls
posted

I have a .ascx control that contains my UltraWebTab and within my UltraWebTab i have 4 tabs that are each a control.  i am trying to pass 2 properties from the main page to each tab and for the licfe of me can not figure out how to get them into the tab controls.  i can get them from the main page into the control that contains the UltraWebTab  but i can nto get them from there tio the individual tabs.

any thougths, suggestions?

 

i'm using 9.2 btw

 

Parents
  • 24497
    posted

    Hi Shawn,

    If I understood correctly you want to find reference to a child control located in ContentPane of TabItem. If that is the case, then you should use standard method of dot-net FindControl. Since you have chain of naming containers, you should search through all of them in exact order. For example, you have TextBox2 located in first tab of WebTab located in WebUserControl2. Below are codes to get reference to that field:

      WebUserControl2 user = this.FindControl("WebUserControl21") as WebUserControl2;
      if(user == null)
       return;
      Infragistics.WebUI.UltraWebTab.UltraWebTab webtab = user.FindControl("UltraWebTab1") as Infragistics.WebUI.UltraWebTab.UltraWebTab;
      if(webtab == null)
       return;
      TextBox tbOnTab1 = webtab.Tabs.GetTab(0).FindControl("TextBox2") as TextBox;
      if(tbOnTab1 != null)
       tbOnTab1.Text = "ok";

Reply Children