locked
windows mobile application portrait page and buttons RRS feed

  • Question

  • I'm using the windows 6.5 develper kit and have started a new project under silverlight phone application. I have 2 buttons on the main page. I have 2 more pages named Page1 and Page2 that i want linked to the 2 buttons on the main page. So in other words when i click on one of the buttons labeled MALE then i want Pag1 to open and so on. I've tried Page1.show but C# isn't recognzing this. I'm new to this so any help would be appreciated.
    Tuesday, May 18, 2010 11:25 PM

Answers

  • Hi,

    We can code like below to show a form in button click event:

     

    private void button1_Click(object sender, EventArgs e)

            {

               

                Form2 f = new Form2();

                f.Show ();

     

            }

     

    private void button2_Click(object sender, EventArgs e)

            {

               

                Form3 f = new Form3();

                f.Show ();

     

            }

     

    If this is not the case, please let me know.

     

    Best regards,
    Guang-Ming Bian - MSFT


    Please remember to mark the replies as answers if they help and unmark them if they provide no help
    Friday, May 21, 2010 5:56 AM