PDA

Click to See Complete Forum and Search --> : String Conversion? Should be simple.


OneSource
Apr 2nd, 2002, 01:44 PM
Hi.

I'm trying to populate a BSTR variable with a value from an edit control on a form that I have created a variable for (m_Edit). m_Edit is a CString object, but I keep getting a conversion error.

Does anyone know how to do this?

Also, a web reference for data type conversations in Visual C++ would be handy also.

Thanks in advance.

CornedBee
Apr 3rd, 2002, 05:54 AM
BSTR str = m_Text.AlllocSysString(); ???

OneSource
Apr 4th, 2002, 07:52 AM
That's just what I was looking for. Your example did the trick!

Thanks, again. :)