Converting textBox1->Text into a basic string.
How would I do this in Visual C++ 9?

The first question would be why do you want to do the conversion? There may be a way to do what you want without doing the conversion.

I believe that the (default?) string type used for Text member of a textBox in Visual C++ 2008 (which I believe is the same as Visual C++ 9) is System::String or String^ which I believe uses the Unicode char set which I believe in Windows is the _wchar_t type (which I believe is typedefed to wchar_t), which obviously isn't the same thing as char. I assume you are trying to go from System::String to char*, in which case I would try looking here:

Help->Index->wchart type->converting System::String

Where Help is the Help tab/button/option at the top of the IDE screen and the arrows are subsequent choices/search items.

Be a part of the DaniWeb community

We're a friendly, industry-focused community of developers, IT pros, digital marketers, and technology enthusiasts meeting, networking, learning, and sharing knowledge.