07-13-2012 10:51 AM
Hello,
I try to use viOpen function with an IP Adress stored in a variable.
The function wants a ViChar*
I tryed all i can imagine : converting in string, c-string and byte array to cast in ViChar* but all failed.
Sometimes, the compiler tell me an illegal cast, other times le program crashs when executing the function.
Can someone to help me ?
(P.S : I work in C++).
07-13-2012 11:01 AM
Have you looked at the included examples that are installed when you install NI-VISA and NI-488.2?
In XP, they are located at C:\Documents and Settings\All Users\Documents\National Instruments\NI-488.2\Examples and C:\Documents and Settings\All Users\Documents\National Instruments\NI-VISA\Examples
07-17-2012 04:48 AM
I don't have those examples because I use Windows 7.
I found programming samples in C:\ProgramData\Agilent\Agilent IO Libraries Programming Samples\ but that not help me because no one show how to use a variable to give the adress string to the viOpen function.
07-17-2012 08:33 AM - edited 07-17-2012 08:34 AM
@Hlodwig wrote:
I don't have those examples because I use Windows 7.
I found programming samples in C:\ProgramData\Agilent\Agilent IO Libraries Programming Samples\ but that not help me because no one show how to use a variable to give the adress string to the viOpen function.
The NI examples will be in a different directory for Windows 7. They are there. I have Windows 7 on a laptop at home.
EDIT: Since you are using Agilent's software, why are you here????
These message boards are for NI software and hardware.
Agilent has their own message boards.