Performs a formatted write and read through a single call to an operation.
ViStatus viVQueryf(ViSession vi, ViString writeFmt, ViString readFmt, ViVAList params)
viVQueryf&(ByVal vi&, ByVal writeFmt$, ByVal readFmt$, params as Any)
GPIB INSTR, Serial INSTR, TCPIP INSTR, TCPIP SOCKET, VXI INSTR, VXI SERVANT
Name | Direction | Description |
---|---|---|
vi |
IN |
Unique logical identifier to a session. |
writeFmt |
IN |
String describing the format of write arguments. |
readFmt |
IN |
String describing the format of read arguments. |
params |
IN/OUT |
A list containing the variable number of write and read parameters. The write parameters are formatted and written to the specified device. The read parameters store the data read from the device after the format string is applied to the data. |
Completion Codes | Description |
---|---|
VI_SUCCESS |
Successfully completed the query operation. |
Error Codes | Description |
---|---|
VI_ERROR_INV_OBJECT |
The given session reference is invalid. |
VI_ERROR_RSRC_LOCKED |
Specified operation could not be performed because the resource identified by vi has been locked for this kind of access. |
VI_ERROR_IO |
Could not perform Read/Write operation because of I/O error. |
VI_ERROR_TMO |
Timeout occurred before Read/Write operation completed. |
VI_ERROR_INV_FMT |
A format specifier in the writeFmt or readFmt string is invalid. |
VI_ERROR_NSUP_FMT |
The format specifier is not supported for current argument type. |
VI_ERROR_ALLOC |
The system could not allocate a formatted I/O buffer because of insufficient resources. |
This operation is similar to viQueryf(), except that the params parameters list provides the parameters rather than the separate arg parameter list
![]() |
Note Because the prototype for this function cannot provide complete type-checking, remember that all output parameters must be passed by reference. |
Related Topics