Hello,
I am not sure of what is causing the error. We know the serial port and NI-VISA are operating correctly because you can perform a loopback test successfully. Is it possible that the cable you are using or the instrument does not have the appropriate pin out? Could you post an NI-Spy capture; I'd like to see the commands leading up to the read operation. I would expect that if you are able to successfully open and write to the serial port, that if you received an error it would be a parity error, framing error (different baud rates), or a timeout error. This way I can see exactly what VISA calls are being made up to the error; you can launch NI-SPy from Start -> Programs -> National Instruments -> NI-Spy. Here are instructions in case you haven't used it before:
http://digital.ni.com/public.nsf/websearch/8D890EC09B15C05A86256E6F007E3E86?OpenDocument
You can also attempt to use the VISA Interactive Control (VISAIC) from Start -> Programs -> National Instruments -> VISA -> VISA Interactive Control, however, these calls should generally be the same VISA calls as from your development environment. I would definitely try communicating through VISAIC since this will allow you to execute and see results leading up in a step by step fashion. When you launch it you'll want to double click your serial resource and then the Basic I/O tab (if you see these tabs... usually light blue), and then use the write and read sub-tabs. As a final general suggestion, can you verify the command you are writing to the instrument in the user manual, and then try writing it using VISAIC. More specifically, does your instrument understand the command "*idn?" and reply with a description of itself? This would be a good place to start with VISAIC to ensure you have established successful communication. Your instrument may require a termination character (such as a carriage return or linefeed) in order to accept commands; in VISAIC you would use the "slash code" to indicate such characters, for example, sending *idn? with a linefeed termination character you would type (without quotes) "*idn?\n"... or for a carriage return you would use \r in place of \n.
Let's take a look at the NI-Spy capture, and if you can confirm the step-by-step success of some commands in VISAIC, I think we'll be able to figure out where things are going wrong!
Thanks and looking forward to hearing back!
Best Regards,
JLS