API fonction return CString.
When a API return a string ref (pointer), KBasic copy the pointer address (convert the integer into a string) into the CString of reception
Public Declare Function MyFct Lib "MyLib.dll" () as CString
Dim sRet as CString
sRet = MyFct() 'sRet contain the value of the pointer of the string returned, but sRet doesn't contain the string desired