CComBSTR::CComBSTR

The default constructor sets the m_str member to NULL. The copy constructor sets m_str to a copy of the BSTR member of src.The other four constructors set m_str to a copy of the specified string; however, if you pass a value for nSize, then only nSize characters will be copied, followed by a terminating null character.The destructor frees the string pointed to by m_str.

Syntax

CComBSTR( );

CComBSTR( int nSize, LPCOLESTR sz = NULL );

CComBSTR( int nSize, LPCSTR sz = NULL );

CComBSTR( LPCOLESTR pSrc );

CComBSTR( LPCSTR pSrc );

CComBSTR( const CComBSTR& src );

At a Glance

Header file: Atlbase.h
Platforms:
Versions: 2.0 and later
Complete documentation: Visual C++ documentation

See Also

CComBSTR Overview, CComBSTR Methods