Parker Hannifin acr-motion max api users guide Error Message System, AX SetGraphics, AXSystemErr

Page 17

AX_ SetGraphics

Description Pass Screen Coordinates (in Pixels) of the ZoomBox to the API for Zoom operations

Returns (Integer) 1 on Success, 0 on Failure

Arguments: ByVal iGraphicsOn As Integer

VB Example: 'Turn Graphics On

Call AX_SetGraphics (1)

'Turn Graphics Off

Call AX_SetGraphics (0)

Declaration: Public Declare Function AX_SetGraphics Lib "MotionCore.DLL" _ (ByVal iGraphicsOn As Integer) As Integer

(Error Message System)

AX_SystemErr

Description 'Get the System errors from the DLL if any

Returns (Integer) 1 on Success, 0 on Failure

Arguments: ByVal ErrMsg as String, ByVal ErrSource as String, ByRef ErrLineNum As Long

VB Example: ErrMsg = Space (255) : ErrSource = Space(128)

Call AX_SystemErr (ErrMsg, ErrSource, ErrLineNum)

ErrMsg = Mid (ErrMsg, 1, lstrlen (ErrMsg))

ErrSource = Mid (ErrSource, 1, lstrlen (ErrSource))

frmErrMsg.ErrMsgTxt.Text = Trim(ErrMsg) & vbCrLf & "Source = " & Trim(ErrSource) & vbCrLf

&"Line = " & ErrLineNum ErrDisplayOn = True

Declaration: Public Declare Function AX_SystemErr Lib _

"MotionCore.DLL" (ByVal ErrMsg As String, ByVal ErrSource As String, ByRef ErrLineNum As Long) As Integer

AX_ClearSystemErr

Description

Acknowledgement from Vb to DLL side from user that he got the error MSG.

 

This function also Clear the Error in the DLL Handler.If more errors are in the message

Returns

Handler the Above Call will be Valid again.

(Integer) 1 on Success, 0 on Failure

Arguments:

None

VB Example:

Call AX_ClearSystemErr

Declaration:

Public Declare Function AX_SystemErr Lib _

 

"MotionCore.DLL" (ByVal ErrMsg as String, ByVal ErrSource As String, ByRef ErrLineNum As

 

Long) As Integer

API Users Guide

API Command Descriptions - 17

Image 17
Contents API Parker Hannifin Corporation All Rights Reserved Technical AssistanceContents Acroloop I/O Layout Introduction Getting StartedAPI Command Groups Error Message MDI Mode CommandsJogging & Homing Virtual OverridesDLL Initialization API Command DescriptionsAXInitializeControl AXIsCardPresentParameter Functions AXUpdateParamsFeedback & Status Functions AXDownloadParameters2CardAXGetDistanceToGoCoordinates Bit FunctionsAXGetAxisVelocity AXBitOnAXBitOff Bit Group FunctionsAXGetInputs AXGetOutputsAXGetMasterFlags Jog and Homing FunctionsAXGetMcodeBits AXGetAdcInputsRet = AXJogPlus CurrentAxis AXHomeAxisRet = AXJogPlusFast CurrentAxis Description Code Functions MDI Mode Functions AXLoadGCodeFile AX GetGCodeLineNumberAXStopMDI Virtual OverridesAXExecuteMDI AXSetFov AXSetRov AXSetSovAXInitializeGPH Graphics FunctionsAXSetGphView ViewPort LayoutAX SetGraphics Error Message SystemAXSystemErr AXClearSystemErrAXCycleStart Cycle FunctionsFeedHold This is not an API function but how we effect Feed holdThis is not an API function but how we effect a Reset ResetAuto/Step Mode Map Control SignalsAPI Users Guide Map Mcode Bits