http://www.telerik.com/community/forums/aspnet-ajax/chart/how-to-make-a-horizontal-chart-legend.aspx
<Legend>
<Appearence overflow="Row"></Appearence>
</Legend>
Javascript to open the RadWindow
function launchEditProjectType(projecttypeid) {
var URL = "wfrmAddProjectType.aspx?projecttypeid=" + projecttypeid
window.radopen(URL,
"AddProjectType");
return false;
}
<telerik:RadWindowManager ID="winMgr" runat="server" Modal="True" Skin="Web20" Left="" NavigateUrl="" EnableEmbeddedScripts="true" KeepInScreenBounds="true" Height="550px" Width="610px" Behaviors="Move,Maximize,Close">
<Windows>
<telerik:RadWindow runat="server" ID="editActivity" VisibleStatusbar="False" Skin="Web20" ReloadOnShow="True" Modal="true" Behaviors="Move,Maximize,Close" />
<telerik:RadWindow runat="server" ID="editProjectType" Height="700px" Width="740px" Behaviors="Close" VisibleStatusbar="False" Skin="Web20" ReloadOnShow="true" Modal="true">
</telerik:RadWindow>
</Windows>
</telerik:RadWindowManager>
In the rad window:
<asp:TextBox ID="txtDescription" runat="server" Font-Names="Arial" Font-Size="12px" MaxLength="40" Width="256px" CausesValidation="true"></asp:TextBox>
<asp:CustomValidator ID="cv2" ControlToValidate="txtDescription" runat="server" Display="Dynamic" OnServerValidate="ValidateProjectType" Font-Bold="true" Font-Names="Arial" Font-Size="20px"
ErrorMessage="CPE Year must be unique" SetFocusOnError="true">*</asp:CustomValidator>
<asp:RequiredFieldValidator ID="rfv0" runat="server" ControlToValidate="txtDescription"
ErrorMessage="Description" Font-Names="Arial" Font-Size="12px">*</asp:RequiredFieldValidator>
in the .vb codebehind
Public Sub ValidateProjectType(ByVal sender As Object, ByVal args As ServerValidateEventArgs)
Dim a As Boolean = True
If args.Value() <> "" Then
Dim data As New AdminData
a =
Not data.isDuplicateProjectType(Me.txtDescription.Text, Me.lblProjectTypeID.Text)
Else
a =
False
End If
args.IsValid = False
End Sub
If all validation works, it will try to save. As you can see, I set the custom validator to always fail, yet it tries to save every time. If I don't run this code in a rad window, but in a browser on its own, the validation is fine.
Any thoughts?