or
| adUpload Ajax callback error. Source url returned invalid content: |
| var rawProgressData = {InProgress:true,ProgressCounters:true,CurrentOperationText:'StudentsExcp_200812.txt' System.InvalidOperationException: Collection was modified; enumeration operation may not execute. |
| at System.ThrowHelper.ThrowInvalidOperationException(ExceptionResource resource) |
| at System.Collections.Generic.Dictionary`2.KeyCollection.Enumerator.MoveNext() |
| at Telerik.Web.UI.Upload.ProgressData.Serialize(TextWriter writer) |
| at Telerik.Web.UI.RadProgressContext.Serialize(TextWriter writer) |
| at Telerik.Web.UI.RadUploadProgressHandler.ProcessRequest(HttpContext context) |
| Telerik.RadUploadProgressHandler.ashx?RadUrid=1a569f1e-f1f3-4dea-a8f4-620716f29b64 |
| Did you register the RadUploadProgressHandler in web.config? |
| Please, see the help for more details: RadUpload for ASP.NET Ajax - Configuration - RadUploadProgressHandler. |
| <telerik:RadProgressManager ID="rpmStudentProgress" runat="server" /> |
| <telerik:RadProgressArea ID="rpaStudentProgress" runat="server" |
| ProgressIndicators="FilesCountBar, FilesCount, FilesCountPercent, SelectedFilesCount, CurrentFileName, TimeElapsed" |
| Skin="Gray"> |
| <Localization Uploaded="Uploaded"></Localization> |
| </telerik:RadProgressArea> |
| RadProgressContext context = RadProgressContext.Current; |
| context.CurrentOperationText = file.GetName(); |
| context.SecondaryTotal = arrStudents.Count + " students"; |
| context.SecondaryValue = (i + 1).ToString(); |
| context.SecondaryPercent = Convert.ToInt32((i * 1.0 / arrStudents.Count) * 100); |
| context.CurrentOperationText = exceptFile.GetName(); |
| context.SecondaryTotal = arrExcept.Count + " exceptionalities"; |
| context.SecondaryValue = (j + 1).ToString(); |
| context.SecondaryPercent = Convert.ToInt32((j * 1.0 / arrExcept.Count) * 100); |
| <add path="Telerik.Web.UI.WebResource.axd" verb="*" type="Telerik.Web.UI.WebResource, Telerik.Web.UI, Version=2008.2.1001.35, Culture=neutral, PublicKeyToken=121fae78165ba3d4" validate="false"/> |
| <add verb="*" path="Telerik.RadUploadProgressHandler.ashx" type="Telerik.Web.UI.RadUploadProgressHandler, Telerik.Web.UI"/> |
| Dim MyUserControl As New UserControl |
| Select Case e.CommandName |
| Case RadGrid.InitInsertCommandName, RadGrid.EditCommandName 'here i want to add a postback controling into the RadAjaxManager of the RadGrid |
| MyUserControl = CType(e.Item.FindControl(GridEditFormInsertItem.EditFormUserControlID), UserControl) |
| If Not IsDBNull(CType(MyUserControl.FindControl("btnAddDoc"), Button)) Then |
| RadAjaxManager1.AjaxSettings.AddAjaxSetting(CType(MyUserControl.FindControl("btnAddDoc"), Button), _ CType(MyUserControl.FindControl("lstActiveDocs"), ListBox)) |
| RadAjaxManager1.AjaxSettings.AddAjaxSetting(CType(MyUserControl.FindControl("btnAddDoc"), Button), _ CType(MyUserControl.FindControl("lstRelateDocs"), ListBox)) |
| End If |
| Case "AddDocs" 'here I want to control the button click event |
| MyUserControl = CType(e.Item.FindControl(GridEditFormItem.EditFormUserControlID), UserControl) |
| 'code for button click event |
| ' ... |
| ' ... |
| ' ... |
| Case RadGrid.CancelCommandName 'here i want to remove the postback controling into the RadAjaxManager of the RadGrid |
| For intX As Integer = 1 To RadAjaxManager1.AjaxSettings.Count - 1 |
| RadAjaxManager1.AjaxSettings.RemoveAt(intX) |
| Next intX |
| End Select |
Using an ajaxified RadGrid (latest and greatest version) I have implemented a custom Command Template to facilitate add, edit, insert, update, and cancel actions based on demos here.
This works fine but does not work for editing or deleting if you are using a custom <ItemTemplate>. I say this because as such it relies on a "selected" row or item in the grid. I have the code to select the row on the client side but cannot figure out how to display or enact the selected row when using the custom <ItemTemplate>.
So the questions are:
Thank you,
P.S. Try posting a message with a title of "Custom <CommandTemplate> when using a custom <ItemTemplate>". The server will not accept it.



| <telerik:RadAjaxManager ID="RadAjaxManager1" runat="server" DefaultLoadingPanelID="RadAjaxLoadingPanel1"> | |
| <AjaxSettings> | |
| <telerik:AjaxSetting AjaxControlID="Button_SearchForCustomer"> | |
| <UpdatedControls> | |
| <telerik:AjaxUpdatedControl ControlID="Label_Error" /> | |
| <telerik:AjaxUpdatedControl ControlID="Hidden_InitialSliderValue" /> | |
| <telerik:AjaxUpdatedControl ControlID="Label_CustomerName" /> | |
| <telerik:AjaxUpdatedControl ControlID="Button_SaveStatus" /> | |
| <telerik:AjaxUpdatedControl ControlID="Placeholder" /> | |
| <telerik:AjaxUpdatedControl ControlID="Div_Results" /> | |
| </UpdatedControls> | |
| </telerik:AjaxSetting> | |
| <telerik:AjaxSetting AjaxControlID="Button_SaveStatus"> | |
| <UpdatedControls> | |
| <telerik:AjaxUpdatedControl ControlID="Label_Error" /> | |
| <telerik:AjaxUpdatedControl ControlID="Button_SaveStatus" /> | |
| </UpdatedControls> | |
| </telerik:AjaxSetting> | |
| </AjaxSettings> | |
| </telerik:RadAjaxManager> |
| <div> | |
| <asp:Label runat="server" AssociatedControlID="RadTextBox_Customer_ID" Text="TMS Customer ID:"></asp:Label> | |
| <telerik:RadTextbox runat="server" | |
| id="RadTextBox_Customer_ID" | |
| EmptyMessage="tms id" | |
| LabelCssClass="radLabelCss_Telerik" Skin="Telerik" | |
| Width="125px"></telerik:RadTextbox> | |
| <asp:Button runat="server" ID="Button_SearchForCustomer" Text="Lookup Customer" /> | |
| <br /><br /> | |
| <asp:Label runat="server" ID="Label_Error" CssClass="Error" /> | |
| <div runat="server" id="Div_Results" style="padding-top:10px;"> | |
| <asp:Label runat="server" ID="Label_CustomerName" CssClass="CustomerName" /> | |
| <table> | |
| <tbody> | |
| <tr> | |
| <td colspan="2" align="center"> | |
| <asp:Button runat="server" ID="Button_SaveStatus" Text="Save Credit Change" /> | |
| </td> | |
| </tr> | |
| </tbody> | |
| </table> | |
| </div> | |
| <br /> | |
| <asp:PlaceHolder runat="server" ID="Placeholder" /> | |