IWorksAsyncDriver interface : Abort method

Abort method
Description
VWorks software calls the Abort method to terminate a specific asynchronous task or to terminate all currently executing asynchronous tasks.
To terminate a specific asynchronous task
1
The plugin calls the ErrorAbortRetryIgnoreNonBlocking update to notify VWorks software that an error occurred and to provide a literal string that describes the error.
2
VWorks software does the following:
a
b
The Abort, Ignore and Continue…, Retry, and Diagnostics buttons
The figure on page 41 shows a standard error dialog box.
3
If the user clicks the Abort button, VWorks software calls the Abort method to tell the plugin to terminate the specified asynchronous task.
To terminate all currently executing asynchronous tasks
When the user aborts a run in the Runset Manager, VWorks software calls the Abort method to tell the plugin to terminate all currently executing asynchronous tasks. (All protocols in the run contain asynchronous tasks.)
Note: This is not an emergency stop.
Syntax
 
HRESULT Abort(
[in] BSTR AsyncXML
);
Parameters
 
[in] An Asynchronous Task Command XML block that describes the asynchronous task to be terminated or that contains an Async_TaskID parameter whose Value attribute is 0, which means to terminate all currently executing asynchronous tasks.
Abort method input (terminate a specific asynchronous task)
VWorks software passes an Asynchronous Task Command XML block into the AsyncXML parameter of the Abort method.
Asynchronous Task Command XML block
The Asynchronous Task Command XML block contains the Command element and all its children. This XML block describes the asynchronous task to be terminated.
XML structure
The value of the file attribute for the Velocity11 element is MetaData. See “Velocity11 element” .
 
<Command>
<Parameters>
<Parameter>
<Ranges>
<Range />
...
</Ranges>
</Parameter>
...
</Parameters>
<Locations>
<Value />
...
</Locations>
<AsyncParameters>
<AsyncParameter Name='Async_TaskVWorksID' ... />
<AsyncParameter Name='Async_ErrorDescription' ... />
<AsyncParameter Name='Async_TaskID' ... />
<AsyncParameter Name='Async_Location' ... />
</AsyncParameters>
</Command>
XML elements and attributes
See “Asynchronous Task Command XML block components” .
Example of Abort method input (terminate a specific asynchronous task)
The following code shows a truncated Asynchronous Task Command XML block that is received by the plugin from VWorks software as a string in the AsyncXML parameter of the Abort method. VWorks software tells the plugin to terminate the asynchronous task named Shake, whose plugin-generated asynchronous task ID is 1.
 
<Command Compiler='0' Description='Shake plate' Editor='4' Name='Shake'
NextTaskToExecute='1' ProtocolName='Protocol File - 1.pro' RequiresRefresh='0'
TaskRequiresLocation='1' VisibleAvailability='1'>
<Parameters>
<Parameter Name='Location' Scriptable='1' Style='0' Type='5' Value='9'>
<Ranges>
<Range Value='<auto-select>' />
<Range Value='1' />
<Range Value='2' />
...
<Range Value='8' />
<Range Value='9' />
</Ranges>
</Parameter>
<Parameter Description='Mode to operate in' Name='Mode' Scriptable='1'
Style='0' Type='2' Value='Timed'>
<Ranges>
<Range Value='On' />
<Range Value='Off' />
<Range Value='Timed' />
</Ranges>
</Parameter>
<Parameter Description='Revolutions per minute' Name='RPM' Scriptable='1'
Style='0' Type='8' Value='500'>
<Ranges>
<Range Value='100' />
<Range Value='2000' />
</Ranges>
</Parameter>
...
<Parameter Description='Amount of time to shake'
Hide_if='Variable(Mode) != Const('Timed')' Name='Time for operation in Timed mode'
Scriptable='1' Style='0' Type='8' Units='s' Value='10' />
</Parameters>
<Locations>
<Value Value='9' />
</Locations>
<AsyncParameters>
<AsyncParameter Name='Async_TaskVWorksID' Value='32.13.1' />
<AsyncParameter Name='Async_ErrorDescription'
Value='No response received from the pipette controller. It is recommended that you
click Retry. Ignoring this error may result in an unpredictable move.' />
<AsyncParameter Name='Async_TaskID' Value='1' />
<AsyncParameter Name='Async_Location' Value='9' />
</AsyncParameters>
</Command>
Abort method input (terminate all currently executing asynchronous tasks)
VWorks software passes an Asynchronous Task Command XML block into the AsyncXML parameter of the Abort method.
Asynchronous Task Command XML block
The Asynchronous Task Command XML block contains the Command element and one AsyncParameters element. The AsyncParameters element contains one AsyncParameter element, which contains an Async_TaskID parameter whose Value attribute is 0.
XML structure
The value of the file attribute for the Velocity11 element is MetaData. See “Velocity11 element” .
 
<Command>
<AsyncParameters>
<AsyncParameter Name='Async_TaskID' ... Value='0' />
</AsyncParameters>
</Command>
XML elements and attributes
See “Asynchronous Task Command XML block components” .
Example of Abort method input (terminate all currently executing asynchronous tasks)
The following code is an Asynchronous Task Command XML block that is received by the plugin from VWorks software as a string in the AsyncXML parameter of the Abort method. VWorks software tells the plugin to terminate all currently executing asynchronous tasks (the Async_TaskID parameter’s Value element is 0).
 
<Command Compiler='0' Editor='0' NextTaskToExecute='1' RequiresRefresh='0' TaskRequiresLocation='1' VisibleAvailability='1' >
<AsyncParameters >
<AsyncParameter Name='Async_TaskID' Value='0' />
</AsyncParameters>
</Command>
Related information