CString::AllocSysString

Call this member function to allocate a new Automation–compatible string of the type BSTR and copy the contents of the CString object into it, including the terminating null character. A CMemoryException is thrown if insufficient memory exists. This function is normally used to return strings for Automation.

Syntax

BSTR AllocSysString ( ) const;
throw( CMemoryException );

At a Glance

Header File Afx.h
Platforms
Versions 2.0 and later
Complete documentation Visual C++ documentation

See Also

CString Overview, CString Member Functions, Simple Value Types, ::SysAllocString, ::SysFreeString, CMemoryException