Workflow Engine/Business Rules Engine
I have a small problem using rwf (v2.3) from a Notes client (6.5.2). When a user exits a new document without saving (via the Esc key or a Cancel button), a non-validated document is created and saved anyway. The new document is saved without an associated form. No other code is running in Queryclose or Querysave except the RWF Queryclose agent. Any idea what could cause this behavior?
Use the following in your button to keep the user from being prompted "Do you want to save your changes?" FIELD rwfDocStatus := "state1"; FIELD rwfHasChanged := "new status"; @PostedCommand([FileSave]); @PostedCommand([FileCloseWindow]) Put the following in your QueryClose for the document: @If(rwfHasChanged = "new status":"remove status"; @Command([ToolsRunMacro];"(RWF DOC QUERYCLOSE)");"") The @If will run the agent only if the document has been changed, which will help performace in cases where the doc isn't being transitioned to a new state. The issue is that there is document from the UI as well as a back-end document that the agent operates on when you create a new document and you need to be sure that both are saved. See the sample application under "Docs" for more.