ျမန္မာလို ကိန္းဂဏန္း ႐ြတ္ဖတ္ပံု သ႐ုပ္ျပ ေဆာ့ဝဲပါ စမ္းသပ္ၾကည့္ႏိုင္ပါတယ္။ Windows OS အတြက္ျဖစ္ပါတယ္။ ~~ မြန်မာလို ကိန်းဂဏန်း ရွတ်ဖတ်ပုံ သရုပ်ပြ ဆော့ဝဲပါ စမ်းသပ်ကြည့်နိုင်ပါတယ်။ Windows OS အတွက်ဖြစ်ပါတယ်။
Form.Dispose() = Form never closed. It just died in violent. I should have know that.
Form.Close() event မွာ ထည့္ထားတဲ့ ကုတ္ေတြ ဘာလို႔ မ run ပါလိမ့္ ဦးေဏွာက္ေျခာက္သြားတာ တကယ္ေတာ့ Dispose() function ေခၚမိထားတာကိုး။ ကိုယ့္ Form က အလန္႔တၾကား ေသသြားေတာ့ Form ပိတ္ေၾကာင္း အေၾကာင္းၾကားတဲ့ Event ေတာင္ trigger မျဖစ္ေတာ့ဘူးေပါ့...။ အင္း.... ဒါ ျဖစ္သင့္ပါတယ္။ အလန္႔တၾကား ေသသြားတာပဲ...။
C#: Form.Close() vs Form.Dispose()
When working with a Windows GUI, it may seem unclear whether to use
Form.Close() or Form.Dispose() to get rid of a dialog at runtime.
Form.Close() removes the dialog from sight and calls the Closing() and
Closed() methods. You can still access the form and bring it back later
on.
Form.Dispose() destroys
the dialog and frees its resources back to the operating system. It
does not call the form’s Closing() and Closed() methods. Once disposed,
you may not recall a form.
Which to use? If you have no logic
in the form’s close methods and don’t intend to re-use the form, go with
Dispose(). Otherwise, go with Close(). Some programmers aren’t sure
which to use, and they use both – Close() then Dispose()!