I am trying to do validation on my multiPages which are part of my radtabStrip on each click of the radtab. I am trying to the get the selected index of each tab so that I know which one I am on to do the validation.
I must say I give the new site and F, what a frustrating new site.
I must say I give the new site and F, what a frustrating new site.
<
telerik:RadTabStrip
ID
=
"radESGRTab"
runat
=
"server"
Orientation
=
"HorizontalTop"
MultiPageID
=
"radPageMulti"
ClickSelectedTab
=
"true"
Skin
=
"Web20"
Font-Bold
=
"true"
Font-Size
=
"Large"
Width
=
"800px"
OnClientMouseOver
=
"tabEmployer"
OnClientTabSelected
=
"CheckValidation"
>
<
Tabs
>
<
telerik:RadTab
PageViewID
=
"rdPageInfo"
Text
=
"Soldier Info"
runat
=
"server"
SelectedIndex
=
"1"
></
telerik:RadTab
>
<
telerik:RadTab
PageViewID
=
"rdPageEmploy"
Text
=
"Employer Info"
runat
=
"server"
SelectedIndex
=
"2"
></
telerik:RadTab
>
<
telerik:RadTab
PageViewID
=
"rdpageSurvey"
Text
=
"Survey Info"
SelectedIndex
=
"3"
></
telerik:RadTab
>
<
telerik:RadTab
PageViewID
=
"rdPageAwards"
Text
=
"Employer Awards"
SelectedIndex
=
"4"
></
telerik:RadTab
>
</
Tabs
>
</
telerik:RadTabStrip
>
function
CheckValidation() {
var
tab1 = $find(
'<%=radESGRTab.ClientID %>'
).selectedIndex();
if
(tab1 == 1) {
var
combo = $find(
'<%= ddlSoldCounty.ClientID %>'
);
var
item = combo.get_selectedItem().get_value();
alert(combo.get_selectedItem().get_value());
if
(item == 1) {
alert(
'You must pick a county from Drop Down List'
);
}
}
}
</script>