Converting textBox1->Text into a basic string.

This is a discussion on Converting textBox1->Text into a basic string. within the C++ Programming forums, part of the General Programming Boards category; Converting textBox1->Text into a basic string. How would I do this in Visual C++ 9?...

  1. #1
    Registered User
    Join Date
    Mar 2009
    Posts
    76

    Converting textBox1->Text into a basic string.

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

  2. #2
    Student legit's Avatar
    Join Date
    Aug 2008
    Location
    UK -> Newcastle
    Posts
    156
    This is extremely vague, unless it's just me. I think that we need more info...

  3. #3
    Registered User
    Join Date
    Mar 2009
    Posts
    76
    No not really.
    I just need to know how to convert a string^ to a basic string, in Visual C++ 9.

  4. #4
    Student legit's Avatar
    Join Date
    Aug 2008
    Location
    UK -> Newcastle
    Posts
    156
    Quote Originally Posted by azjherben View Post
    No not really.
    I just need to know how to convert a string^ to a basic string, in Visual C++ 9.
    I'm not sure what you mean... You want to convert a string^ to a basic string? What's the difference? I'm not really a Visual guy, so I'm sure others would love to help!

  5. #5
    tjb
    tjb is offline
    Registered User
    Join Date
    Jan 2009
    Posts
    31
    I'm not an expert on C++/CLI, but I would imagine that the way you would do it is similar to the way you would convert a .NET string to a byte array. System::Text::ASCIIEncoding::GetBytes may be a start, if you're looking at 8-bit extended ASCII characters. I believe there is a text conversion helper function that makes this even easier.

  6. #6
    Registered User
    Join Date
    Dec 2007
    Posts
    65
    Not to mention textBox1 is an instantiation of... what class? Tons of toolkits have a text-box component: wxWidgets, FOX, FLTK, .NET Forms...

Popular pages Recent additions subscribe to a feed

Similar Threads

  1. Replies: 8
    Last Post: 04-25-2008, 02:45 PM
  2. We Got _DEBUG Errors
    By Tonto in forum Windows Programming
    Replies: 5
    Last Post: 12-22-2006, 04:45 PM
  3. Message class ** Need help befor 12am tonight**
    By TransformedBG in forum C++ Programming
    Replies: 1
    Last Post: 11-29-2006, 10:03 PM
  4. Something is wrong with this menu...
    By DarkViper in forum Windows Programming
    Replies: 2
    Last Post: 12-14-2002, 10:06 PM

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21