VS2008常见类型转换

1

1. CString char*

char   m_file[100+1]=""; 

WideCharToMultiByte( CP_ACP,0, filename,-1,m_file, 100, NULL, NULL   );

2. _bstr_t CString

CString str;

_bstr_t str1;

str=(LPCTSTR)(_bstr_t)str1

3. CString _bstr_t

CString str;

_bstr_t str1;

str1=(_bstr_t)str

 

 

你可能感兴趣的:(File,null,360,微软,2010)