locked
c# windows programming RRS feed

  • Question

  • hello,
       i am using visual studio 2008.how to run a particular form in c# windows base programming
    Monday, February 8, 2010 6:16 AM

Answers

  • Hi,
    go to program.cs

    change the form which one you want to run in start up.

     [STAThread]
            static void Main()
            {
                Application.EnableVisualStyles();
                Application.SetCompatibleTextRenderingDefault(false);
    //here you need to change Application.Run(new Form1()); }
    another one after application loaded you can change the form.
    private void button3_Click(object sender, EventArgs e)
            {
                Form2 frm = new Form2();
                frm.Show();
            }
    hope it helps
    Best Regards, C.Gnanadurai ----------------------- Please mark the post as answer if it is helpfull to you
    • Proposed as answer by DiegoCattaruzza Tuesday, February 9, 2010 5:09 PM
    • Marked as answer by eryang Thursday, February 25, 2010 8:38 AM
    Monday, February 8, 2010 6:35 AM
  • Hi,
    yes it is possible have a look at this link
    http://www.gafvert.info/CSRemoteDiskInfo.htm
    i just googled it if you want more results
    free hard disk space remote system c#
    Best Regards, C.Gnanadurai ----------------------- Please mark the post as answer if it is helpfull to you
    • Marked as answer by futurepriya Wednesday, February 10, 2010 7:51 AM
    Tuesday, February 9, 2010 4:40 PM

All replies

  • Hi,
    go to program.cs

    change the form which one you want to run in start up.

     [STAThread]
            static void Main()
            {
                Application.EnableVisualStyles();
                Application.SetCompatibleTextRenderingDefault(false);
    //here you need to change Application.Run(new Form1()); }
    another one after application loaded you can change the form.
    private void button3_Click(object sender, EventArgs e)
            {
                Form2 frm = new Form2();
                frm.Show();
            }
    hope it helps
    Best Regards, C.Gnanadurai ----------------------- Please mark the post as answer if it is helpfull to you
    • Proposed as answer by DiegoCattaruzza Tuesday, February 9, 2010 5:09 PM
    • Marked as answer by eryang Thursday, February 25, 2010 8:38 AM
    Monday, February 8, 2010 6:35 AM
  • Hi,

    if you want a particular Window form to run, Change following line in Program.cs file in your C# project.

    Application.Run(new Form1()); // change this to your form like new Form2()
    Monday, February 8, 2010 6:36 AM
  • hi
    for c# which is the best book
    Tuesday, February 9, 2010 6:11 AM
  • Tuesday, February 9, 2010 6:24 AM
  • hello sir,

           i am doing a project, in dat i am able to calculate the freespace,total space for the  IP address of the system.Is it possible to calculate freespace,total space for any IP address from our system.i am using .net. 








    Regards
    banupriya
    Tuesday, February 9, 2010 3:04 PM
  • Hi,
    yes it is possible have a look at this link
    http://www.gafvert.info/CSRemoteDiskInfo.htm
    i just googled it if you want more results
    free hard disk space remote system c#
    Best Regards, C.Gnanadurai ----------------------- Please mark the post as answer if it is helpfull to you
    • Marked as answer by futurepriya Wednesday, February 10, 2010 7:51 AM
    Tuesday, February 9, 2010 4:40 PM