hallo
CoInitializeEx (NIL, COINIT_APARTMENTTHREADED); // Start
COM on this thread
rm := CoResourceManager.Create; // Create the VISA
COM I/O Resource manager
rm.Open('TCPIP0::127.0.0.1::INSTR', NO_LOCK, 0, '', sess); // Use the resource manager to create a VISA
COM Session
sess.QueryInterface(IID_IMessage, io); // The IVisaSession interface is very general and does not have string reading/writing , we want to be able to read and write to the instrument
io.WriteString('*IDN?', retCount); // Write to the instrument
io.ReadString(1000, readResult); // read the result
Gruss
Peter