Save All button on Dashboard with multiple grids

I have a dashboard that has 2 grids, both are updatable .

One publish and the other subscribe. At the moment, when user press save, it only save the data on the focused dashboard. What I want to allow the user to press save and it saves the data in the subscribe grid first and then save the data in the publish grid.

Can oTrans.Update() & oTrans.NotifyAll() can achieve these? How do I make sure the data in the subscribe dashboard save first?

Are you allowing edits on both dashboards at the same time (with multiple dirty rows enabled on both queries)?
If so, the records on both grids should be in a “pending update” status (RowMod = ‘U’). When you click “SAVE”, it should update both. If not, I would send a bug report to Epicor.

Top grid UBAQ does not allow multiple dirty row.
Bottom grid UBAQ does allow multiple dirty row.

Are you sure when you press save, both grid should update?

My findings so far is if I update data in the bottom grid first, then update data in the top grid, press save, only top grid data stay, if I refresh all grid, bottom grid data will be revert back to the old values.

Same thing will happen if I swap the change order.

Save will only save data on the grid that has focused. I do not think it is a bug from my view.

Both need to allow multiple dirty rows I believe.

I was always under the impression that the refresh and save buttons only affected which grid had focus at the time one was clicked.

That could be true. I haven’t tried it, but that would be something to try.
If not, you would have to set which EpiDataView is the current view and run the Save.

Can you shed some light on how to set the EpiDataView to become the current view? Which event is the best place to put it?

I tried to put it on the BeforeToolClick and change some data so that the dataview for the bottom grid has data change. Doesn’t seem to work.

private void MainController_BeforeToolClick(object sender, Ice.Lib.Framework.BeforeToolClickEventArgs args)
	{
		if (args.Tool.Key == "SaveTool" ||  args.Tool.Key == "SaveMenuTool")
		{
			
			EpiDataView reschJobDV = (EpiDataView) oTrans.EpiDataViews["V_AP_RescheduleJobV2_1View1"];

			MessageBox.Show(oTrans.LastView.ViewName);

			if(oTrans.LastView != reschJobDV)
			{
				MessageBox.Show("oTrans Update");
				reschJobDV.CurrentDataRow.BeginEdit();
			    reschJobDV.CurrentDataRow["JobHead_CommentText"] = "XXXXX";
				reschJobDV.CurrentDataRow["RowMod"] = "U";
				reschJobDV.CurrentDataRow.EndEdit();
				oTrans.Update();
				oTrans.NotifyAll();
			}
		}
	}

You can use below code to call save button.

MainController.AppControlPanel.HandleToolClick(“SaveTool”, new Infragistics.Win.UltraWinToolbars.ToolClickEventArgs(MainController.MainToolManager.Tools[“SaveTool”], null));

1 Like

That can save, however I cannot seem to make the bottom grid to save first before the top grid.

I tried putting the Save code in the BeforeToolClick and get the top grid to focus and save, but I still cannot control the sequence of the save.

i have experienced multiple UBAQ update in one dashboard as major hurdle(only updates currently focused grid). kind of bug. i have overcome this by various approach.

option 1) do a hierarchical grid … and try update . you would use dynamic query adapter in client code to instigate updates in UBAQ BPM and achieve your goal.

option 2)

lets say you have 3 UBAQ grid in dashboard.

a) parent grid lets call it as “poheader”

b) child grid lets call it as “podetail”

c) child grid lets call it as “porel”

now, when you update “poheader” and/or any child grid

d) output changed child grid data to a server location in csv format (do client code “catch toolclick save event”)

e) in parent UBAQ “poheader”, BPM Directive configuration - look for the csv file, read it and update child records.

i have used both options, been in production for over 6 months… runs fine.

In either way, i would recommend to output a log file as the update progress. just in case if you need any review at later stage.

option 3) - least preferred - depends upon your transaction volume - use client code to update

instead of pressing save. place a button in the screen. clicking that should look all changes in all grids and update it.

I’m looking over this post and would like more information on how you accomplished it. My project is to create and or modify a engineered part with subassembly engineered parts from a quote part design. I have 6 Updatable BAQs in a dashboard and each work to create the parts and revisions needed. I have to change a field before It will generate or change the record so I’m putting a button on a Tracker view to force save but haven’t found the object to enact the save. Any suggestions or options would be appreciated.