Hello, I am wondering how you read input from a text box in microsoft visual studio Forms.

I'm trying to make a program that reads text box data and tells you the readout, but I don't know what to type to return the data typed in a text box.

Please help.

If your textbox is named textBox1, the textBox1->Text member contains the text that was typed in. Place a button on your form and double click it, and type your code in the button handler to display it in a message box or whatnot.

Please be a little more spesific

In the designer, drag a button onto your form. Double click it, which will put an event handler in your code automatically. If there isn't a textbox already, then add one and make a note of it's name by looking in the properties window on the right side.
(let's assume the textbox's name is textBox1.


To start off, in that event handler that the ide generated type something like MessageBox::Show(textBox1->Text);

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.