views:

35

answers:

1

some one in tips and tricks say like this plz i cant understand that plz if u could provide saple code for that answer ,i could understand it.actullay iam facing this problem in my application where iam using C#.net,VS 2008,windows mobile 6 professional.

they told like this below one

If you have to support multiple screen sizes/resolutions, form inheritance is an excellent way to do it. Basically you design your form to fit the standard 320x240 screen. To support a different screen size, you just add a new form, inherit from your custom form (instead of just Form), and then re-arrange the controls as necessary.

A: 
class BaseForm
{
    protected Label label1;
    protected Label label2;

    BaseForm()
    {
        InitializeComponent();
        DoLayout();
    }

    protected virtual void DoLayout() { }
    // etc.
}

class Form240_320 : BaseForm
{
    protected override void  DoLayout()
    {
        // re-position controls for 320x240
        // etc.
    }

}

class Form320_240 : BaseForm
{
    protected override void  DoLayout()
    {
        // re-position controls for 320x240
        // etc.
    }
}
ctacke
thank for providing it .plz could u have any link of this sample because iam having many controls in my form.and my another question is to test the application in emmulator,we should follow how many emulators and which emulators r good to test and tell me mostly used emulator for testing
karim