or

No luck with: Telerik.Web.UI.RadAsyncUpload.Modules.Flash.isAvailable = function () { return false; };No luck with: Telerik.Web.UI.RadAsyncUpload.Modules.Silverlight.isAvailable = function() { return false; };
Hi Guys,
I haven't had the need to use much javascript...so please forgive my ignorance.
Im trying to write some client-side validation code.
The premise is that each listbox item hold a delimited value that contains a ProductId and other ProductIds it cannot coexist with.
For example value=1,4,6,8. This is intrepreted that the ProductId of this item =1 and it cannot be added to any list box which already has Products 4,6 or 8 in it.
I have successfully done this server side with the following code and I am trying to reproduce client-side with javascript. Any help would be appreciated.
Private Sub RadListBoxDestination_Transferring(sender As Object, e As Telerik.Web.UI.RadListBoxTransferringEventArgs) Handles RadListBoxDestination.Transferring Dim aryNoCoExist As Array Dim i As Integer Dim Product As Integer Dim Cancel As Boolean = False Dim BoxItem As Telerik.Web.UI.RadListBoxItem Dim NoCoExist As String = "" Me.ErrorLabel.Text = "" If RadListBoxDestination.Items.Count > 0 Then Product = GetProductId(e.Items(0).Value) 'GetProductId returns the first delimited string item For Each BoxItem In RadListBoxDestination.Items If Len(NoCoExist) Then NoCoExist = NoCoExist & "," & GetNoCoExist(BoxItem.Value) 'GetNoCoExist returns the remaining delimited string minus the first item Else NoCoExist = GetNoCoExist(BoxItem.Value) End If Next aryNoCoExist = Split(NoCoExist, ",") For i = 0 To aryNoCoExist.GetUpperBound(0) If Product = aryNoCoExist(i) Then Cancel = True Me.ErrorLabel.Text = "Product Not Compatible with Existing Selections" End If Next e.Cancel = Cancel End IfEnd Sub
<telerik:RadListBox runat="server" ID="RadListBoxSource" Height="200px" Width="300px" AllowTransfer="true" TransferToID="RadListBoxDestination" AllowTransferOnDoubleClick="True" EnableDragAndDrop="True"> <ButtonSettings TransferButtons="Common" ShowDelete="False" ShowReorder="False" ShowTransferAll="False"></ButtonSettings> </telerik:RadListBox> <telerik:RadListBox ID="RadListBoxDestination" runat="server" Height="200px" Width="300px" AllowTransfer="true" TransferToID="RadListBoxSource" AllowTransferOnDoubleClick="True" EnableDragAndDrop="True" OnClientTransferring="onTransferring"> <ButtonSettings TransferButtons="Common" ShowTransfer="false" ShowDelete="False" ShowReorder="False" ShowTransferAll="False"></ButtonSettings> </telerik:RadListBox>
Thanks....
David
<body id="SendNotifications"> <telerik:RadStyleSheetManager ID="RadStyleSheetManager1" runat="server"> <StyleSheets> <telerik:StyleSheetReference Path="~/Styles/Site.css" /> <telerik:StyleSheetReference Path="~/App_Themes/Skins.skin" /> </StyleSheets> </telerik:RadStyleSheetManager> <form id="form1" runat="server"> <div class="oops"> <asp:ScriptManager ID="notifyScriptManager" runat="server" /> <telerik:RadFormDecorator ID="RadFormDecorator1" runat="server" Skin="Office2010Silver" DecoratedControls="All" /> <asp:FormView ID="NotificationForm" runat="server" Width="100%" Height="300px" > <EditItemTemplate> <table class="IncDetails"> <tr> <td> <asp:CheckBox runat="server" ID="chkIncLogger" Checked="false" Text="Notify Incident Logger" /> </td> <td> <asp:CheckBox runat="server" ID="chkIncAssignee" Checked="true" Text="Notify Current Assignee" Enabled="false" /> </td> <td> <asp:CheckBox runat="server" ID="chkNotifyManager" Checked="false" Text="Notify Notify Manager" /> </td> <td> <asp:CheckBox runat="server" ID="chkIncDistList" Checked="false" Text="Notify Distribution List " /> </td> </tr> <tr> <td> <asp:CheckBox runat="server" ID="chkIncCreator" Checked="false" Text="Notify Incident Creator" /> </td> <td> <asp:CheckBox runat="server" ID="chkIncOrigAssignee" Checked="false" Text="Notify Original Assignee" Enabled="false" /> </td> <td> <asp:CheckBox runat="server" ID="chkIncConsumer" Checked="false" Text="Notify Consumer" Enabled="false" /> </td> </tr> <tr> <td> <asp:Button ID="btnSave" runat="server" Text="Save" /> </td> <td> <asp:Button ID="btnClose" runat="server" Text="Close" /> </td> </tr> </table> </EditItemTemplate> </asp:FormView> </div> </form></body></html>function ShowNotificationForm() { window.radopen("/Inc/Notifications.aspx", "NotifyDialog"); return false; }<telerik:RadWindowManager ID="RadWindowManager1" runat="server"><Windows><telerik:RadWindow ID="NotifyDialog" runat="server" ReloadOnShow="true" ShowContentDuringLoad="false" Modal="true" Width="900px" Height="760px"></telerik:RadWindow></Windows>