I need to call into a Win32 API to get a series of strings, and I would like to return an array of those strings to JScript. This is for script that runs on local machine for administration scripts, not for the web browser.
My IDL file for the COM object has the interface that I am calling into as:
HRESULT GetArrayOfStrings([out, retval] SAFEARRAY(BSTR) * rgBstrStringArray);
The function returns correcty, but the strings are getting 'lost' when they are being assigned to a variable in JScript.
The question is: What is the proper way to get the array of strings returned to a JScript variable?