Repeats that last automation operation performed in the active automation container.
#include "ltwrappr.h"
L_INT LAutomation::Redo (dwFlags=0);
Reserved for future use. Must be 0.
Value | Meaning |
---|---|
SUCCESS | The function was successful. |
< 1 | An error occurred. Refer to Return Codes. |
This function can be called for each process "undone" in the active automation container by calling LAutomation::Undo. For example, if LAutomation::Undo has been called three times, to undo three processes, then calling LAutomation::Redo can redo those three processes. The first call to LAutomation::Redo will redo the first process; the second call will redo the second process and the third call will redo the third process.
This example shows how to redo the last automation operation.
L_INT LAutomation_RedoExample(LAutomation &lauto)
{
L_INT nRet;
nRet = lauto.IsValid ();
if ( SUCCESS == nRet ) /* check the validity of the automation handle */
{
L_BOOL fCanRedo ;
/* query the ability of redoing */
fCanRedo = lauto.CanRedo () ;
if ( fCanRedo )
{
/* redo the last automation operation */
nRet = lauto.Redo () ;
if(nRet != SUCCESS)
return nRet;
}
}
else
{
return nRet ;
}
return SUCCESS ;
}