CALL_EXTERNAL [message #31630] |
Tue, 30 July 2002 07:43 |
zaygula
Messages: 2 Registered: July 2002
|
Junior Member |
|
|
Hi all,
I am not able to pass below strings from IDL 5.5 to c/c++ interface
running on Red Hat Linux 7.3 2.96-110. The same code worked well on
IDL 5.4 on solaris
The fragment of the code is shown below.
FUNCTION vgam_wrap_do_query, query, dest
FORWARD_FUNCTION lib_name, lib_func_name
IPaddress = 'localhost'
DBname = 'gas'
DBlogin = 'ziko'
DBpasswd = 'tabes'
rc = call_external(lib_name('gavaidl'), $
lib_func_name('gava_idl_do_query'),$
query, dest, n_elements(dest), $
IPaddress, $
DBname, $
DBlogin, $
DBpasswd, $
/i_value, $
/portable )
return, rc
end
IDL>dest=strarr(16)
IDL>query='SELECT * FROM table1'
%Compiled module: LIB_NAME.
%Compiled module: LIB_FUNC_NAME.
printed results from c/c++ interface
cout<<IPaddress[0].s<<endl; = (null) expected output 'localhost'
cout<<DBname[0].s <<endl; = (null) expected output 'gas'
cout<<DBlogin[0].s <<endl; = (null) expected output 'ziko'
cout<<DBpasswd[0].s <<endl; = (null) expected output 'tabes'
|
|
|