March 2000
Intermediate to advanced
576 pages
18h 13m
English
StringToOleStr Function
function StringToOleStr(const Str: string): PWideChar;
The StringToOleStr function converts a string to a
wide string suitable for passing to OLE and COM routines.
StringToOleStr is a real
function.
The wide string is dynamically allocated, and you must make sure you
free it by calling the Windows API function
SysFreeString.
procedure Demo;
var
OleStr: PWideChar;
begin
OleStr := StringToOleStr(S);
try
SomeOLEProcedure(OleStr);
finally
SysFreeString(OleStr);
end;
end;| OleStrToString Function, OleStrToStrVar Procedure, PWideChar Type, String Keyword, StringToWideChar Function, WideChar Type, WideCharLenToString Function, WideCharLenToStrVar Procedure, WideCharToString Function, WideCharToStrVar Procedure, WideString Type |
Read now
Unlock full access