Hi,
I have a page "Main.aspx" with an UltraWebTab containting 3 tabs: initially, only the first tab is enable.
When I press a button in the first tab, I need to enable the other two tabs, but the UltraWebTab control is contained in the "Main.aspx" page and not in the aspx page visualized in the first tab where I have the button.
I tried to use Me.Parent.Page.FindControl but with no success.
Can you help me?
Thank you
Hi accountinfragistics,
Thank you for posting in the community.
When using a content page for your tabs, they are rendered inside an iframe . You can access that from your Main.aspx page and subscribe a clientside onclick handler for your button. A similar example with WebDialogWindow is presented at:
http://blogs.infragistics.com/forums/t/62665.aspx
To get the button from your content page on your main page you could use something similar to:
var iframe = igtab_getTabById("UltraWebTab1").Tabs[0].elemIframe; var button = iframe.contentDocument.forms[0].children[2].children["Button1"];
Please note that UltraWebTab is now outdated and has been retired as of version 11.2. You can find a detailed list of the retired controls and their respective replacements at:
http://blogs.infragistics.com/blogs/taz_abdeali/archive/2011/11/17/asp-net-product-changes-in-2011-volume-2.aspx
Feel free to contact me if you have any questions.
Hi Petar,
thank you for your reply, but I think I have the opposite probelem :-)
In fact, I have mai UltraWebTab in Main.aspx page; this UltraWebTab has three tabs:
-1 -> redirects to Page1.aspx
-2 -> redirects to Page2.aspx
-3 -> redirects to Page3.aspx
Initially only tab 1 is enabled; in Page1.aspx I have a UltraWebButton ("Button1"); when I click on it, I need to enable tab2 and tab3.
Thank you again
Thank you for your reply.
Attached is a sample illustrating your scenario. Notice that the clientside click event of the input located in Page1.aspx (tab 0 in UltraWebTab) is handled in the main page (Default.aspx).
Please let me know if this helps.
Hi Petar, thank you very much for your example.
I still have a doubt: in my scenario the button is a server-side control (a WebImageButton); in this example there is a client-side control (<input type="button">).
Great, it works!
thank you very much.
I'll try your last example asap.
Please feel free to contact me if you have any further questions.
Upon further research, it may be more efficient to handle the clientside click of your button in Page1.aspx and access the UltraWebTab in the parent page (Main.aspx). Here is some sample code for Page1.aspx:
<script type="text/javascript"> function buttonHandler() { parent.igtab_getTabById("UltraWebTab1").Tabs[1].setEnabled(true); } </script> <asp:Button Text="text" ID="Button1" runat="server" OnClientClick="buttonHandler()" />