Mauaka
asked on
String conversion
How can I convert CString to COleVariant?
Problem statement:
Currently, i'm developing an MFC program that reads file status from files and wishes to display them in Excel format. However, the function I got needs and input of COleVariant.
In Summary, filestatus returns CString while the function for displaying excel requires COleVariant.
Is there a way to convert CString to COleVariant and vise versa?
Request.... for future reference, is there a site / link which holds codes in data format conversion? such as CString WCHAR WSTRING?
Thank you for reading.
Dozo yoroshiku Onegaishimasu.
Problem statement:
Currently, i'm developing an MFC program that reads file status from files and wishes to display them in Excel format. However, the function I got needs and input of COleVariant.
In Summary, filestatus returns CString while the function for displaying excel requires COleVariant.
Is there a way to convert CString to COleVariant and vise versa?
Request.... for future reference, is there a site / link which holds codes in data format conversion? such as CString WCHAR WSTRING?
Thank you for reading.
Dozo yoroshiku Onegaishimasu.
ASKER CERTIFIED SOLUTION
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
CString strData = "hi";
COleVariant Variant;
Variant = strData;
its working.
Raj