Compartilhar via


_bstr_t::operator =

 

The latest version of this topic can be found at _bstr_t::operator =.

Microsoft Specific**

Assigns a new value to an existing _bstr_t object.

Syntax

  
      _bstr_t& operator=(  
   const _bstr_t& s1   
) throw ( );  
_bstr_t& operator=(  
   const char* s2   
);  
_bstr_t& operator=(  
   const wchar_t* s3   
);  
_bstr_t& operator=(  
   const _variant_t& var   
);  

Parameters

s1
A _bstr_t object to be assigned to an existing _bstr_t object.

s2
A multibyte string to be assigned to an existing _bstr_t object.

s3
A Unicode string to be assigned to an existing _bstr_t object.

var
A _variant_t object to be assigned to an existing _bstr_t object.

END Microsoft Specific

Example

See _bstr_t::Assign for an example of using operator=.

See Also

_bstr_t Class