Ive got a form (we'll call it Form1), which has a button that opens up another little input form (Form2). Form2 contains 4 inputs, i want to return those from Form2 back to Form1.
How do i do that? Ive tried creating an overloaded ShowDialog() method with a return value, but that caused a System.StackOverflowException in mscorlib - always nice.
Am i complicating something simple? Because it feels like i am...
I hate Slack, but Teams is much worse - maybe they've already optimized it, but it was a huge slog the last time I've checked about half a year ago. I miss my Skype.
Question
$phinX
Ive got a form (we'll call it Form1), which has a button that opens up another little input form (Form2). Form2 contains 4 inputs, i want to return those from Form2 back to Form1.
How do i do that? Ive tried creating an overloaded ShowDialog() method with a return value, but that caused a System.StackOverflowException in mscorlib - always nice.
Am i complicating something simple? Because it feels like i am...
So, how do i return a value from the form?
Link to comment
https://www.neowin.net/forum/topic/347559-c-return-a-value-from-a-form/Share on other sites
19 answers to this question
Recommended Posts