IAPI::URLEncode

method URLEncode.  ( Available since v2.34.3  )

Allows app and script to encode an URL string which contains unsafe and characters with accents.

Unsafe characters are in this list: { "<>%\^[]`+$,@:;/!#?=& }.

 

This function is  useful before passing URL parameters to OpenHttpFile(…), OpenHttpFileEx(…) and

OpenHttpAndPost(…).

 

HRESULT URLEncode(
  BSTR srcURLParams,
  BSTR *pVal
);

Parameters

srcURLParams

[in] . String containing URL parameter list (aka “name1=val1&name2=val2&name3=val3…” )

*pVal

[out, retval] . Returned converted string or the original if no conversion occurred.

 

Return Values

S_OK

The operation was successfull.

E_UNEXPECTED

An unexpected error occoured.

E_FAIL

A general error occoured.

See Also

IAPI