Are you using Call Library Function Node to call prefix_close()? If so, the function node will automatically convert a resource name to a session. Check out the KB at http://digital.ni.com/public.nsf/websearch/FB001AA027C8998386256AAD006C142D?OpenDocument
"the Call Library Function Node performs this conversion. If you wire a VISA resource name or VISA refnum to an 32-bit integer input terminal of a Call Library Function Node, the node coerces the refnum into a valid session ID, which you can use in your external code. You also can use this method to call functions in the Visa32.dll directly from LabVIEW."
You could also get the VISA session from the instrument driver with:
prefix_GetAttributeViSession(instHandle, "",TEST_ATTR_IO_SESSION, &visaSession);
wher
e prefix is the prefix of your instrument driver.
Hope this helps.
A.S.
Anu Saha
Academic Product Marketing Engineer
National Instruments