Hi - I am using Infragistics webtab (v 10.2) to move between two aspx pages and here is code snippet.
<
ig:WebTab ID="WebTab1" runat="server" Height="200px" Width="300px" EnableValidation="true" EnableViewState="false">
<Tabs><ig:ContentTabItem runat="server" Text="Tab 1" ContentUrl="Page1.aspx">
</ig:ContentTabItem>
<ig:ContentTabItem runat="server" Text="Tab 2" ContentUrl="Page2.aspx">
</ig:ContentTabItem></Tabs>
<PostBackOptions EnableLoadOnDemandUrl="true" EnableLoadOnDemand="true" EnableReloadingUnselectedTab="true" EnableAjax ="true"/>
<AutoPostBackFlags SelectedIndexChanged ="On"/>
</ig:WebTab>
Here is the issue I am facing -
When I move from Tab1 (Page1.aspx) to Tab2 (Page2.aspx) Page1.aspx is loaded as expected, but Page2.aspx is loaded twice.
Am I missing any settings?
Appreciated quick response.
IE calls the TabSelectedIndexChanged twice, so you need to do something like this:
( note that these loadcnt(s) are maintained in a persisted class and cleared on page_load)
Private Sub tabRotation_SelectedIndexChanged(ByVal sender As Object, ByVal e As Infragistics.Web.UI.LayoutControls.TabSelectedIndexChangedEventArgs) Handles tabRotation.SelectedIndexChanged ' infragistics webtab event model wants to run the tabindex changed event always twice ' way too much over head involved, limit this to once only Select Case tabRotation.SelectedIndex
'Case 0 is my default tab and is loaded by default
Case 1 ' Description If (MSS_Rotation.tabDescriptionloadcnt = 0 AndAlso Request.Browser.Browser <> "IE") OrElse (MSS_Rotation.tabDescriptionloadcnt = 1 AndAlso Request.Browser.Browser = "IE") Then LoadDescription() End If MSS_Rotation.tabDescriptionloadcnt += 1 Case 2 ' Scheduling If (MSS_Rotation.tabSchedulingloadcnt = 0 AndAlso Request.Browser.Browser <> "IE") OrElse (MSS_Rotation.tabSchedulingloadcnt = 1 AndAlso Request.Browser.Browser = "IE") Then LoadSchedulingTab() End If MSS_Rotation.tabSchedulingloadcnt += 1 Case 3 ' Tags If (MSS_Rotation.tabTagsloadcnt = 0 AndAlso Request.Browser.Browser <> "IE") OrElse (MSS_Rotation.tabTagsloadcnt = 1 AndAlso Request.Browser.Browser = "IE") Then LoadTagsTab() End If MSS_Rotation.tabTagsloadcnt += 1 Case 4 ' Students If (MSS_Rotation.tabStudentsloadcnt = 0 AndAlso Request.Browser.Browser <> "IE") OrElse (MSS_Rotation.tabStudentsloadcnt = 1 AndAlso Request.Browser.Browser = "IE") Then LoadStudents() End If MSS_Rotation.tabStudentsloadcnt += 1 End Select End Sub
*Also, note that if you let the webtab sit for a couple of minutes (on a fired off tab), *then* switch to another tab *WHICH HAS NOT BEEN LOADED ON DEMAND*:
1. for IE, it might never fire off the event
2. for IE, it might never fire off the 2nd selectedindexchanged (so a persisted Boolean might be a better choice versus a counter style implementation)
Hello,
This fix will be available in the next service release which is currently scheduled for May 18. For more information about our service release schedule please see the Service Release calendar which can be found at the following location:
http://es.infragistics.com/support/service-releases.aspx
Please let me know if I can be of any further assistance.
Hi,
I have the new service release now. But my tab is still acting the same. Was this bug fixed in this release?
Please let me know if I need to do something else to make it work.
Thanks.
History in tfs shows that it was already merged into RELEASE branch. It means that it was already tested and verified. In most cases time between fixes and services releases take around 1-2 months. That was fixed less than a month ago. I guess, it should be available in next service release.
I have Infragistics 11.1.20111.2064. The problem still exists. Is there a workaround to fix it?
Please let me know.
Hello again,
I upgraded my Infragistics to the latest service release i.e. 11.1.20111.2158. And the above problem IS STILL NOT fixed!!!!
Can someone from Infragistcs please reply? I have to get my project out and I cannot go with this double post-backs!
Hi Preet919,
That is possible that you have different scenario compare to original report.
It would be great if you write simplest possible sample (aspx and aspx.cs files are enough), zip those files and attach within Options tab. Also provide exact steps to reproduce that issue.
The fix for this issue should have gone out a while ago. Could you provide me with some more information about your implementation? It is possible that you may be facing a new issue that wasn't covered by the fix for the previous issue.