I understand how to get text out of a textbox in visual C++ but what I'm after is how to break the text up at each space and put those parts into an array.

For example I have a group of numbers: 2 5 9 10 44 ect and I want to put each number into an array. I know how to do it in just c++ but how about when I get it from a text box?

Thanks

Recommended Answers

All 2 Replies

Perhaps read the text from the text box into a string, and use std::stringstream to break it up.

I will give that a shot, thanks. I was not sure if I could do that since I am using a text box now, I have not done anything but console programming yet.

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.