L_AutSetCurrentTool

#include "ltaut.h"

L_LTAUT_API L_INT L_AutSetCurrentTool(pAutomation, nTool)

pAUTOMATIONHANDLE pAutomation;

/* pointer to an automation handle */

L_INT nTool;

/* tool id */

Manually sets the current tool in an automation handle without using the toolbar.

Parameter

Description

pAutomation

Pointer to an automation handle.

nTool

An integer value that represents the tool to set. For more information about tools, tool identifiers and toolbar button; refer to the Lttbdlln.chm help file.

Returns

SUCCESS

The function was successful.

< 1

An error occurred. Refer to Return Codes.

Comments

This function lets you simulate a toolbar, instead of using one provided by LEAD Automation.

Required DLLs and Libraries

LTAUT

For a listing of the exact DLLs and Libraries needed, based on the toolkit version, refer to Files To Be Included With Your Application

See Also

Functions:

L_AutGetCurrentTool, L_AutSetToolbar, L_AutGetToolbar

Topics:

The Automation Toolbar

Example

This example will set the Line tool in a vector automation handle.

 L_INT AutSetCurrentToolExample(pAUTOMATIONHANDLE pAutomation)
{
   L_INT nRet;
   /* Assume pAutomation is a valid vector automation handle, and no toolbar has been set */
   nRet = L_AutSetCurrentTool( pAutomation, ID_TOOL_VECTOR_LINE );
   if(nRet != SUCCESS)
      return nRet;
   return SUCCESS;
}