or
Available Sub Categories<br /><telerik:RadListBox ID="rlbAvailableSubcategories" runat="server" Height="200px" Width="200px" AllowTransfer="true" TransferToID="rlbMappedSubcategories" TransferMode="Copy" ButtonSettings-ShowTransferAll="false" SelectionMode="Multiple" AllowDelete="false" AllowTransferOnDoubleClick="True" ButtonSettings-TransferButtons="TransferFrom"></telerik:RadListBox>Mapped<br /><telerik:RadListBox ID="rlbMappedSubcategories" runat="server" AllowTransferDuplicates="false" Height="200px" Width="200px" AllowDelete="true"></telerik:RadListBox><asp:CustomValidator ID="ValidateMappedSubcategories" EnableClientScript="True" runat="server" ErrorMessage="You must add at least 1 category" ClientValidationFunction="rlbMappedSubcategoriesHasItems" ControlToValidate="txtAddLongDesc" ValidateEmptyText="True" OnServerValidate="rlbMappedSubcategoriesHasItems_Validate" Display="Dynamic"></asp:CustomValidator><script type="text/javascript"> function rlbMappedSubcategoriesHasItems(source, args) { var list = $find("<%= rlbMappedSubcategories.ClientID %>"); args.IsValid = list.get_items().get_count() > 0; }</script><script type="text/javascript" language="javascript"> // Catches events fired by the RadGrid (paging) and jumps page to the top var postbackElement; Sys.WebForms.PageRequestManager.getInstance().add_beginRequest(beginRequest); Sys.WebForms.PageRequestManager.getInstance().add_pageLoaded(pageLoaded); function beginRequest(sender, args) { postbackElement = args.get_postBackElement(); } function pageLoaded(sender, args) { if (typeof (postbackElement) === "undefined") { return; } // Uses the MasterTable ClientID if ((postbackElement.id) === "ctl00_CphJam_ctl00_RadGrid1_ctl00") { window.scrollTo(0, 160); } } </script> void RadGrid1_InsertCommand(object sender, GridCommandEventArgs e) {........ var result = blala.ValidateAndSave(...); if (result.ResultCode == ValidationResultCode.Ok) { AddMessage("The data were successfully validated and Saved!"); NewAllEntriesToAccount(); } else { AddMessage("Please check the data. The following errors were found: ");
AddErrorList(RadGrid1.Columns[meldung.SpaltenIndex].UniqueName); }GridEditableItem item = (GridEditableItem)e.Item; TextBox combo = (TextBox)item[itemm.ItemArray[0].ToString().Replace(" ", "")].Controls[0]; combo.BackColor = GetColor((ClArt)itemm.ItemArray[2]); if (IsInErrorList(itemm.ItemArray[0].ToString().Replace(" ", ""))) { combo.BorderStyle = BorderStyle.Solid; combo.BorderWidth = 2; combo.BorderColor = System.Drawing.Color.Red; }