Hello,
I'm struggling with the individual validation of my tabs. I browser the internet and the telerikforums but i wom't get it to work.
I have the following tabstrip :
<telerik:RadTabStrip ID="tabManagement" runat="server" MultiPageID="mpManagement"
SelectedIndex="0" CausesValidation="true" OnClientTabSelected="UpdateValidationGroup">
<Tabs>
<telerik:RadTab Text="Algemeen" Value="Algemeen">
</telerik:RadTab>
<telerik:RadTab Text="Contactpersoon" Value="Contactpersoon">
</telerik:RadTab>
<telerik:RadTab Text="Adresgegevens" Value="Adresgegevens">
</telerik:RadTab>
<telerik:RadTab Text="Openingstijden" Value="Openingstijden">
</telerik:RadTab>
<telerik:RadTab Text="Winkelpagina" Value="Winkelpagina">
</telerik:RadTab>
<telerik:RadTab Text="Instellingen webshop" Value="InstellingenWebshop">
</telerik:RadTab>
<telerik:RadTab Text="Google" Value="Google">
</telerik:RadTab>
<telerik:RadTab Text="Statistieken" Value="Statistieken">
</telerik:RadTab>
<telerik:RadTab Text="Account" Value="Account">
</telerik:RadTab>
</Tabs>
</telerik:RadTabStrip>
On the clientevent TabSelected I run the script:
function UpdateValidationGroup(tabStrip, eventArgs) {
var selectedTab = tabStrip.get_selectedTab();
if (selectedTab != null) {
tabStrip.ValidationGroup = selectedTab.get_value();
}
}
I use the Value-property of the selectedtab to set the validationgroup. That works fine. The validationgroup of validationcontrols in the RadPageViews have the same name as the Value-property of the selected tab. In my tab itself the validation fires but I can still navigate to another tab even when validation is false. What I want is that I cannot navigate to another tab as long as one of my validators in my selected tab is false.
When I hardcode the validationgroup of my TabStrip then it works fine.
Can anyone tell me what I'm doing wrong.
Thx
Patrick
I'm struggling with the individual validation of my tabs. I browser the internet and the telerikforums but i wom't get it to work.
I have the following tabstrip :
<telerik:RadTabStrip ID="tabManagement" runat="server" MultiPageID="mpManagement"
SelectedIndex="0" CausesValidation="true" OnClientTabSelected="UpdateValidationGroup">
<Tabs>
<telerik:RadTab Text="Algemeen" Value="Algemeen">
</telerik:RadTab>
<telerik:RadTab Text="Contactpersoon" Value="Contactpersoon">
</telerik:RadTab>
<telerik:RadTab Text="Adresgegevens" Value="Adresgegevens">
</telerik:RadTab>
<telerik:RadTab Text="Openingstijden" Value="Openingstijden">
</telerik:RadTab>
<telerik:RadTab Text="Winkelpagina" Value="Winkelpagina">
</telerik:RadTab>
<telerik:RadTab Text="Instellingen webshop" Value="InstellingenWebshop">
</telerik:RadTab>
<telerik:RadTab Text="Google" Value="Google">
</telerik:RadTab>
<telerik:RadTab Text="Statistieken" Value="Statistieken">
</telerik:RadTab>
<telerik:RadTab Text="Account" Value="Account">
</telerik:RadTab>
</Tabs>
</telerik:RadTabStrip>
On the clientevent TabSelected I run the script:
function UpdateValidationGroup(tabStrip, eventArgs) {
var selectedTab = tabStrip.get_selectedTab();
if (selectedTab != null) {
tabStrip.ValidationGroup = selectedTab.get_value();
}
}
I use the Value-property of the selectedtab to set the validationgroup. That works fine. The validationgroup of validationcontrols in the RadPageViews have the same name as the Value-property of the selected tab. In my tab itself the validation fires but I can still navigate to another tab even when validation is false. What I want is that I cannot navigate to another tab as long as one of my validators in my selected tab is false.
When I hardcode the validationgroup of my TabStrip then it works fine.
Can anyone tell me what I'm doing wrong.
Thx
Patrick