-5

I have been searched about creating input dialog in windows form using visual c++ but I didn't found useful resource Is there any exist function do this task ? I know how to create an empty dialog but how I can add text box and buttons ?

Form ^ dlg1 = gcnew Form();
dlg1->ShowDialog();
Lightness Races in Orbit
  • 378,754
  • 76
  • 643
  • 1,055

2 Answers2

0

No. You have to design a dialog with a field for information entry, put it up and retrieve the information entered.

Tim Bergel
  • 499
  • 3
  • 9
0

Yes, actually. Just use a standard VBScript InputBox, which can be used in C++ via the IActiveScript interface. See my answer to a similar question for the full code example:

https://stackoverflow.com/a/52808263

It will automatically resize the dialog to the contents you specify in the arguments, so don't worry about creating your own dialog. Microsoft made one for you, so why not just use it? :)