hi team,
As we are using the web datagrid while updating the row cell.we are getting the error like
"Async request failed " please find the screen shot same in the below
<
="server"
="True">
>
="clsColorChange">
/>
="55%"
<%
%>
="buttonOK">
:1px solid black;">
="center">
solution:
="return"
please let me know the issues
thanks
Hi ranganathanpalanisamy,
The code you have provided seems to be correct. In order to be able to investigate this issue further, I would need a small isolated sample, reproducing the issue.
Thank you.
Thanks for your reply
aspx code :
<div id="mndiv" runat="server"> <table style="width: 100%;"> <tr> <td align="right" style="height: 30px;" class="tableElement"> <asp:Button ID="btnSaveSolution" CssClass="ButtonText" runat="server" Text="Save Solution" Visible="True" /> </td> </tr> <tr> <td> <igrid:WebDataGrid ItemCssClass="RowBackGround" AutoGenerateColumns="False" runat="server" ID="uwgInformation" Width="100%" Height="580px" DataKeyFields="ErrorNumber" EnableDataViewState="false"> <Columns> <igrid:BoundDataField Key="ErrorDate" Header-Text="Error Date" Width="25%" Header-CssClass="clsColorChange"> <Header CssClass="clsColorChange" Text="Error Date" /> <Header Text="Error Date" CssClass="clsColorChange"></Header> </igrid:BoundDataField> <igrid:BoundDataField Key="ErrorMessage" Header-Text="Error Description" Width="55%" Header-CssClass="clsColorChange"> <Header CssClass="clsColorChange" Text="Error Description" /> <Header Text="Error Description" CssClass="clsColorChange"></Header> </igrid:BoundDataField> <igrid:BoundDataField Key="solution" Header-Text="Solution" Width="20%" Header-CssClass="clsColorChange" DataType="System.String"> <Header CssClass="clsColorChange" Text="Solution" /> <Header Text="Solution" CssClass="clsColorChange"></Header> </igrid:BoundDataField> <igrid:BoundDataField Key="ErrorNumber" Header-Text="Error Number" Width="20%" Header-CssClass="clsColorChange"> <Header CssClass="clsColorChange" Text="Error Number" /> <Header Text="Error Number" CssClass="clsColorChange"></Header> </igrid:BoundDataField> </Columns> <Behaviors> <igrid:EditingCore AutoCRUD="false"> <Behaviors> <igrid:CellEditing> </igrid:CellEditing> </Behaviors> </igrid:EditingCore> <igrid:Activation> </igrid:Activation> <igrid:Selection> </igrid:Selection> </Behaviors> </igrid:WebDataGrid> </td> </tr> <tr> <td align="center" class="tableElement"> <div ID="eventList" runat="server" class="controlPanelEvent"></div> <asp:Label ID="lblMessage" runat="server" CssClass="" Visible="true"></asp:Label><asp:HiddenField ID="hdnClientEvents" runat="server" /> </td> </tr></table>
vb.net code :
Protected Sub btnSaveSolution_Click(ByVal sender As Object, ByVal e As System.EventArgs) Handles btnSaveSolution.Click Dim i As Integer Dim errorObj As ProMISError = Nothing Dim errorList As ProMISErrorCollection = Nothing Try errorList = New ProMISErrorCollection Do While i <= uwgInformation.Rows.Count - 1 errorObj = New ProMISError
errorObj.ErrorNumber = CType(Me.uwgInformation.Rows(i).Items(3).Text, Integer) ' errorObj.ErrorNumber = CType(Me.uwgInformation.Rows(i).Cells(3).Text, Integer) ' If Me.uwgInformation.Rows(i).Cells(2).Text = Nothing Then If Me.uwgInformation.Rows(i).Items(2).Text = Nothing Then errorObj.Solution = Nothing Else 'errorObj.Solution = Me.uwgInformation.Rows(i).Cells(2).Text errorObj.Solution = Me.uwgInformation.Rows(i).Items(2).Text End If errorObj.Status = "C" errorList.Add(errorObj) i = i + 1 Loop Me.errorDao = ProMISLoggerDAO.GetPromisErrorDao 'save error solution errorDao.SaveErrorSolutions(errorList) Me.lblMessage.Text = "Saved Successfully" Me.lblMessage.CssClass = "SuccessMessage" Me.lblMessage.Visible = True Me.GetErrorGridData() Catch promisEx As ProMISException pError = New ProMISError(-1, "G", "E", promisEx.ToString()) lblMessage.Visible = True lblMessage.CssClass = "ErrorMessage" Catch getEx As Exception pError = New ProMISError(-1, "G", "E", getEx.Message() & ":~~:" & getEx.StackTrace()) Me.lblMessage.Visible = True Me.lblMessage.CssClass = "ErrorMessage" Finally
The data source is missing and there are custom classes, which are not present, used in your code, so I could not run it. However, I see that you have AutoCRUD set to false. In this case you should handle the RowUpdating event to manually save the changes to the data source.
Let me know if you have any questions.
I'm just checking if you still need assistance with the matter.