iSeller Commerce
iSeller POS Retail
iSeller POS F&B
iSeller POS Express
Crosslight
WebUI
ClientUI
What's New
Download Trial
Web Solution
Mobile Solution
Enterprise Solution
Custom Development
Blog
Community
Latest Development Blogs
ForumPostTopic
Browse By Tag
I can Insert, Update and Delete records normally with BatchUpdate set to false... but I can't delete or update when it is set to true. It returns an alert with the message (for example):
WebGrid failed to update 2 out of 2 changes due to errors. Please review and correct your changes.The following records were not updated:-Record '14037 06-01-2010 10:10:00<4206' : Unable to find the record '14037 06-01-2010 10:10:00<4206' in the datasource.-Record '14037 13-01-2010 10:10:00<4206' : Unable to find the record '14037 13-01-2010 10:10:00<4206' in the datasource.
The weird thing is the "<" between date and 4206... The same error returns when trying to delete. Only Inserting records with batchupdate returns no error.Other related issue:I cant review changes because an alert saying "WebGrid instance can't be found. Please make sure you launch this form from WebGrid UI" appears. My webgrid is inside a javascript generated WebDesktopWindow
function CreateWindow() { var wnd = dm.GetWindow('testing'); if (wnd == null) { wnd = new window.parent.WebDesktopWindow(); wnd.Text = 'Just for testing'; wnd.Name = 'testing'; wnd.AllowMinimize = "Yes"; wnd.AllowMaximize = "Yes"; wnd.AllowResize = "Yes"; wnd.ContentURL = "Testing/ShowTesting.aspx"; wnd.ContentMode = "UseIFrame"; dm.Windows.Add(wnd); wnd.Show(); wnd.ResizeTo(800, 600); wnd.MoveToCenterDesktop(); wnd.BringToFront(); } else { wnd.Activate(); } }
My page is too extensive to upload as sample, I just would like an opinion on what it might be. I'll try to send a sample later. By the way... it is almost the same as this sample.
Oh...! About the version: I've updated using the Update Manager, but it returned an error. I've tried to update again and no error returned. Image as attachment.
TIA.
Edit: On FireFox it doesnt event terminate "Submitting all changes to server..."
Regarding the error, I suspect based on the error message it is caused by the composite primary key of the table. Do you mind sending us the a few row of the problematic table and the setting you are using for the WebGrid?In my test, using the BatchUpdate_Enterprise.aspx sample in the WebDesktopWindow does not result in any error.The latest WebGrid 7 and WebUI Framework 3 build is build 400 and build 750 respectively. Please confirm that you already have the latest build in your project bin folder.
Well... after hours trying to find a solution, no success achieved:
When I set BatchUpdate to false, it works as a charm. But when I set it to true, it cant Update / Delete. I can only Select and Insert with BatchUpdate.
I've checked my stored procedures manually and they're working fine (as confirmed when setting BatchUpdate to false). Please see attached image.
Haven't tried to solve 'Review' on WebDesktopWindow yet.
The "Review Changes" issue seems to be caused by a bug. A bug report has been submitted to the developer.
Regarding the BatchUpdate issue, please provide us with your WebGrid setting you are using and a few row data of the problematic table. What kind of composite key you are using? The column data type?
Table1* Cod (int)* Dhe (smalldatetime)* Cz (int)(other columns)Table2* Cod (int)* Dhe (smalldatetime)* Cz (int)* Cd (int)(other columns)
My WebGrid (modified example):
<ISWebGrid:WebGrid ID="WebGrid1" runat="server" Height="393px" UseDefaultStyle="True" Width="100%" DefaultStyleMode="Elegant" ViewStateStorage="None" StateRestorationLevel="Low" onbatchupdate="WebGrid1_BatchUpdate" DataSourceID="ISDataSource1" DataMember="Table1" > <LayoutSettings Hierarchical="True" AllowAddNew="Yes" AllowColumnMove="Yes" AllowDelete="Yes" AllowEdit="Yes" AllowExport="Yes" AllowFilter="Yes" AllowGrouping="Yes" AllowSelectColumns="Yes" AllowSorting="Yes" AutoFilterSuggestion="True" GridLines="Vertical" GroupByBoxVisible="True" HeaderClickAction="SortMulti" HideColumnsWhenGrouped="Yes" NewRowLostFocusAction="AlwaysUpdate" PromptBeforeDelete="True" RowLostFocusAction="AlwaysUpdate" ShowFilterStatus="True" ResetNewRowValuesOnError="False" VerboseEditingInformation="True" PagingMode="ClassicPaging" PagingStyleUI="Slider" PagingSize="10" AllowBatchUpdate="True" SelectFirstCellOnAdd="true" AllowMultipleSelection="Yes" ColumnFooters="Yes" MarkDefaultValuesAsDirty="false"> <BatchUpdateSettings AllowReviewChanges="True" NotifyOnLostFocus="True" /> </LayoutSettings> <FlyPostBackSettings PostHiddenFields="false" PostInputControls="false" PostViewState="false" /> <RootTable Caption="Table1" DataMember="Table1"> <ChildTables> <ISWebGrid:WebGridTable Caption="Table2" DataMember="Table2"> <Columns> <ISWebGrid:WebGridColumn Caption="Cod" DataMember="Cod" DataType="System.Int32" Name="Cod" /> <ISWebGrid:WebGridColumn Caption="Dhe" DataMember="Dhe" DataType="System.DateTime" Name="Dhe" /> <ISWebGrid:WebGridColumn Caption="Cz" DataMember="Cz" DataType="System.Int32" Name="Cz" /> <ISWebGrid:WebGridColumn Caption="Cd" DataMember="Cd" DataType="System.Int32" Name="Cd" /> <ISWebGrid:WebGridColumn Caption="Field1" DataMember="Field1" Name="Field1" /> </Columns> </ISWebGrid:WebGridTable> </ChildTables> <Columns> <ISWebGrid:WebGridColumn Caption="Cod" DataMember="Cod" DataType="System.Int32" Name="Cod" Width="100px" /> <ISWebGrid:WebGridColumn Caption="Dhe" DataMember="Dhe" DataType="System.DateTime" Name="Dhe" Width="100px" /> <ISWebGrid:WebGridColumn Caption="Cz" DataMember="Cz" DataType="System.Int32" Name="Cz" Width="100px" /> <ISWebGrid:WebGridColumn Caption="Field1" DataMember="Field1" DataType="System.Boolean" Name="Field1" Width="100px" /> <ISWebGrid:WebGridColumn Caption="Field2" DataMember="Field2" DataType="System.Boolean" Name="Field2" Width="100px" /> </Columns> </RootTable> </ISWebGrid:WebGrid>
I have a dataset configured to work with stored procedures, but I had to change the "Dhe" in the TableAdapters from DateTime to String, because otherwise the relationship was not working right in webgrid (couldn't add child rows). I can't touch db structure. An example of a row from Table1 can be seen on previous screenshot...Im downloading 2009/R2 now... My webgrid version is 7.0.7200.306, WebUI v3.0.5000.705 and ISDataSource v1.0.1500.210.TIA
Edit: All components updated. Its odd, but I just change AllowBatchUpdate from "true" to "false" and webgrid works... but no batch updated support, of coure.
It seems there is an issue with WebGrid BatchUpdate and multiple column composite key. I am currently logging this as a bug. I will inform you if there is any update or progress regarding this issue.
Thank you. I'll wait for the solution...
I am getting a similar error. There are 3 grids on the page 1 comes from a usercontrol, but all use only 1 DataKeyField. I stepped through the batchupdate calls and verified the data was updated correctly through my stored procedure that are called from the batchupdate, but this error message still shows.
NOTE: I am maintaining the DataTable which the grid is bound to with server side code and stored procedures. i.e. I am not using a objectdatasource of any kind.
We have recently released WebUI Studio 2009 R2 Service Pack 1 which includes the fix for this issue. Please click here to read the official press release.
You could also read which fix or enchancement included in the latest build by visiting the support page and clicking the control name located on the Right Pane "Latest Builds".
NOTE: WebGrid version 7.0.7200.401
Our office had updated the Intersoft libraries with "Update Manager" on 02/09/10 to the latest version. As We are now on version 7.0.7200.401, I'm assuming we have the latest hotfix.
We have multiple screens that still produce this javascript message. In all cases the data was correctly displayed and passed back to the server and processed successfully in the BatchUpdate. Is there some flag, method or event we could use to avoid this javascript message as we know the process was sucessful?
Is there further documentation you could recommend we view to explain what validation is being used to create this problem?
The fix discussed in this thread is for composite key scenario. In your case, since you are only using 1 datakeyfield this fix probably will not solve the issue.
Could you supply us with a screenshot of the error message or a running sample so we could try to replicate the scenario in our environment. If the sample is not possible perhaps you could detailed the steps require to replicate the issue.
or
Choose this if you're already a member of Intersoft Community Forum. You can link your OpenID account to your existing Intersoft Social ID.
Choose this if you don't have an Intersoft account yet. Your authenticated OpenID will be automatically linked to your new Intersoft account.
Enter your Wordpress Blogname