SECUserTool Class
class SECUserTool: public CObject
The SECUserTool class provides an abstraction of a user-tool.
Defined in: usertool.h
Comments
A user-tool is an executable that can be spawned programmatically by the application. An SECUserTool object encapsulates the filename, command-line arguments and initial directory that describe how and where the executable should be run. In addition, the SECUserTool interface contains an Execute member function that uses these attributes to launch the user-defined tool.
In addition to the SECUserTool member functions, several global functions exist for operating on a set of user-tools. For example, to serialize an array of user-tools, use the ReadUserToolFile or WriteUserToolFile functions. To append an array of user-tools to a menu, use the AppendUserTools function. Finally, to delete an array of user-tools, use the EmptyUserToolArray function.
See the TOOLMENU sample in the \SAMPLES\TOOLKIT\STANDARD\UIEXT\TOOLMENU directory for a demonstration of this class.
See Also
Class Members
Public Members
BOOL IsWaitEnabled() const
Indicates whether the "wait" state is enabled or disabled for your application.
BOOL SetWaitEnabled(BOOL b)
Sets the "wait" state to force your application to wait for a spawned process to terminate before
LPCTSTR GetMenuText() const
Returns the menu text associated with this user-defined tool.
LPCTSTR SetMenuText(LPCTSTR str)
Sets the menu text associated with this user-tool.
LPCTSTR GetCommand() const
Returns the absolute path and filename of the executable that is the user-defined tool.
LPCTSTR SetCommand(LPCTSTR str)
Sets the absolute path and filename of the executable that is the user-tool.
LPCTSTR GetArgs() const
Returns the command-line arguments that will be passed to the user-defined tool upon execution.
LPCTSTR SetArgs(LPCTSTR str)
Sets the command-line arguments that will be passed to the user-tool upon execution.
LPCTSTR GetDirectory() const
Returns the absolute path of the directory in which the user-defined tool will be initially executed.
LPCTSTR SetDirectory(LPCTSTR str)
Sets the absolute path of the directory in which the user-tool will be initially executed.
UINT GetShowFlag() const
Returns show window status.
UINT SetShowFlag(UINT i)
Sets flag for show window status.
BOOL Execute(CStringList* pReplacements) const
Runs the user-tool.
SECUserTool& operator=(const SECUserTool& rhs)
Sets the members of one SECUserTool based on another.
SECUserTool* Clone() const
Makes a copy of this SECUserTool object.