e used as an input in viFindNext (). retcnt Number of matches. instrDesc Returns as string identifying the location of a device. Strings can then be passed to viOpen ( ) to establish a session to the given device. Figure 12.42 Parameters of viFindRsrc function. descriptors. With this resource descriptor strings we build the list that will be returned by the service operation. xsdstringArray * returnList=new xsd_stringArray; if (numInstrs > 0) xsd_string * instrList = new xsd_string[numInstrs]; instrList [0] = instrDescriptor; for (int i =1; i numInstrs; i++) char buffer [VI_FIND_BUFLEN] ; status = viFindNext (findList, buffer) ; /* find next descriptor */ if (status >= VI_SUCCESS) instrList [i] = new char [VI_FIND_BUFLEN] ; strcpy (instrList [i] buffer) ; returnList- > set (instrList, numInstrs) 2. ExecuteCommand operation: ExecuteCommand operation takes as param- eters the instrumentDescriptor and the command to be executed. The response from the executeCommand operation contains the following fields: Service Delivery Platforms complexType name = "CommandResult" > < sequence > <element name = "instrumentDescriptor" type="string" nillable = "true"/ <element name = "executionStatus" type="string" nillable="true"/> element name = "errorMessage" type="string" nillable="true"/ < element name = "result" type = "string" nillable="true"/> < element name = "executedCommand" type = "string" hillable="true"/ element name = "instrumentstatus" type="string" nillable= "true"/ </sequence > /complexType > InstrumentDescriptor the visa address of the instrument which executed the command. InstrumentStatus: the status of the instrument after the command execution. Result: the result of the command execution returned by the instrument. ExecutionStatus: the status of the operation. The value is OK in case of suc- cess of ERROR in case something went wrong during the service execution (resource not available, communication errors, various errors). ErrorMessage: in case of error, this field will contain the error cause and some text 