I need help. I have a window-shaped application. Whenever I click “close” a form, the application should close.
Can anybody help me.
Regards, Justin Samuel.
After your explanation:
In Form1, do something like:
Form2 f2 = new Form2(); f2.ShowDialog(); this.Close(); Application.Exit();
This suggests that Form2 can be shown Modal (Dialog), which I believe is true
Winforms will automatically exit when the main form is closed. The main form is the form that is created and passed to the Application.Run method in the main application method.
, , - , ( ), .
, , , , . , .
Form_FormClosed, Application.Exit() - Form_FormClosing, , .
, Application.Exit().
Application.Exit()
Source: https://habr.com/ru/post/1721975/More articles:Hard page refresh using javascript - javascriptConvert VB6 AES Rijndael Block Cipher to C # by Phil Fresle - c #Eclipse пропускает контрольные точки при отладке java - debuggingphp google analytics redirect question with 'header' - redirecthttps://translate.googleusercontent.com/translate_c?depth=1&pto=aue&rurl=translate.google.com&sl=ru&sp=nmt4&tl=en&u=https://fooobar.com/questions/1721974/cmake-how-to-add-compiler-flags-to-non-default-compiler&usg=ALkJrhiuD4oNITK7OuyQxCkqSwt4mYSbOgFadeIn FadeOut with jQuery with a twist - jqueryis it possible to build a debugger around a java script engine? - javaMINIX 3 as a dns server? - cWeb application, which route to go? - javaHow to include this 12-line method in a single-line LINQ expression? - c #All Articles