Here is how you refresh the dataset in post processing on E10
Erp.Contracts.SalesOrderSvcContract orderSvc = Ice.Assemblies.ServiceRenderer.GetService<Erp.Contracts.SalesOrderSvcContract>(Db);
SalesOrderTableset OrderDs = orderSvc.GetByID(<YourOrderNum>);
this.dsHolder.Attach(OrderDs);
Here is how to do it in E9
DEFINE VARIABLE hSalesOrder AS HANDLE NO-UNDO.
RUN bo/SalesOrder/SalesOrder.p PERSISTENT SET hSalesOrder.
RUN GetByID IN hSalesOrder(INPUT <YourOrderNum>, {&output_dataset_SalesOrderDataSet}).
DELETE OBJECT hSalesOrder.