AnsweredAssumed Answered

ErrorQuery operation using AgilentRfSigGen IVI-COM driver.

Question asked by lcorrigan on Feb 27, 2009
Latest reply on Feb 27, 2009 by lcorrigan
Sorry if this is the wrong posting area but I didn't see a specific one for Remote Control of Signal Generators.
I'm trying to control my N5182A MXG Signal Generator using the AgilentRFSigGen IVI-COM driver within VS2005 C#.NET.  I'm not attempting to make it IVI compliant and have just made a direct call to the Agilent device specific class.
I'm trying to add error checking to all the property sets, and methods by using the "ErrorQuery" method.  The manual states that this function can be used when the "QueryInstrumentStatus" is set to True, to retrieve error details when the driver detects an instrument error.

I have set this flag to true, but what has me baffled is how the error actually gets queried or reported. ie: The ErrorQuery method returns nothing, and states you need to pass in the ErrorCode and Instrument error message.  ??? What exactly does this method do then? I would have thought the "ErrorQuery" is querying the error since I'm used to Queries returning something other than Void.
Does the "QueryInstrumentStatus" cause the commands to throw an exception or something?

If someone could give me a hand outlining which commands I would do to accomplish setting a value or running a method and doing error checking after, it would go a long way for me.  I'm trying to avoid adding a second Class to wrap up all the Driver commands to add error checking.