အခု article လေးကတော့ window form size change တာကို တဖြည်းဖြည်းနဲ့ ပြောင်းသွားအောင် လုပ်တဲ့ animation အသေးစားလေးပါပဲ ။ Programming အခြေခံလို့လဲ ပြောလို့ ရပါတယ်။
Changing Form Dimensions
ဆိုကြပါစို့ ။ မူရင်း Default size ကနေပြီးပဲ change လိုက်ရအောင်. အရင်ဆုံး button ၂ ခုကို ထည့်ပါမယ်။ Text property မှာ တစ်ခုကို big form size ဆိုပြီးပေးမယ် နောက်တစ်ခုကို small form size ဆိုပြီးပေးမယ်။ small form size ဆိုတဲ့ button ရဲ့ click_event မှာ အောက်ကကုတ်လေးထည့်ပေးလိုက်ပါ။
while (this.Width < 200)
{
this.Width--;
Application.DoEvents(); //allow the Form to display its new size before
//the next iteration
}
while (this.Height < 200)
{
this.Height--;
Application.DoEvents();
}
နောက် big form size ဆိုတဲ့ button click_event မှာ အောက်က ကုတ်ကိုထည့်ပေးလိုက်ပါ။
while (this.Width > 400)
{
this.Width++;
Application.DoEvents(); //allow the Form to display its new size before
//the next iteration
}
while (this.Height > 400)
{
this.Height++;
Application.DoEvents();
}
ဒါဆိုရင် သူဟာ form size ချိန်းတာကို တဖြည်းဖြည်းနဲ့ ချိန်းသွားပါလိမ့်မယ်။ ပိုပြီးကြည့်ကောင်းသွားပါလိမ့်မယ်။
More info => http://www.vcskicks.com/size-transform.php
C# window Form Resize Animation
Wednesday, September 01, 2010
min that thant
Subscribe to:
Post Comments (Atom)
Posted in 
No Response to "C# window Form Resize Animation"
Post a Comment