|
|
|
|
|
ActionDeclareUndo (Function) In french: ActionDeclareUndo Declares how to cancel an action that was added by ActionDo. This function MUST be called when running the procedure passed to ActionDo. ActionDo(FEN_MonEditeur, ProcCréeLib, "Nouveau")
INTERNAL PROCEDURE ProcCréeLib(sLib)
pNouveau is Control
pNouveau <- ControlCreate("LIB_" + GetIdentifier(), typText, 150, 150, 80, 20)
pNouveau..Caption = sLib
ActionDeclareUndo(ProcAnnuler)
INTERNAL PROCEDURE ProcAnnuler()
ControlDelete(pNouveau)
END
END
ActionDeclareUndo(AnnulerOperation, CLIENT.IDClient)
INTERNAL PROCEDURE AnnulerOperation(nIDClient)
IF HReadSeekFirst(CLIENT, IDClient, nIDClient) THEN
SourceToScreen()
END
END
Syntax
ActionDeclareUndo(<WLanguage procedure> [, <Parameter 1> [... [, <Parameter N>]]])
<WLanguage procedure>: Procedure name Name of WLanguage procedure to run. The code of this procedure must allow to cancel the action created by ActionDo.This procedure is called when pressing Ctrl + Z or during the call to ActionUndo. Note: Using an internal procedure allows direct access to local variables. <Parameter 1>: Any optional type First optional parameter that will be passed to the procedure. In most cases, these parameter correspond to values used to restore the previous status. <Parameter N>: Any optional type Nth optional parameter that will be passed to the procedure. In most cases, these parameter correspond to values used to restore the previous status. Remarks Use conditions A WLanguage error occurs if this function is called outside a procedure added by ActionDo.
This page is also available for…
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|