Results 1 to 5 of 5

Thread: How do I open a form in WinForm

  1. #1
    Ace1000 is offline VB.NET Forum Newbie
    .NET Framework
    .NET 4.5
    Join Date
    Aug 2015
    Posts
    8
    Reputation
    0

    How do I open a form in WinForm

    I am new to WinForm.
    I have Visual Studio Express 2015 I have a project with 5 forms.
    Form1, Form2, Form3, Form4, Form5.

    Form1 opens by default when I start application. I am working on Form5.
    Question:
    How do I open ONLY Form5 for testing?

    I don't want to put a link from Form1 to Form5. I am not talking about writing some code to open a form.

  2. #2
    IanRyder is offline VB.NET Forum All-Mighty
    .NET Framework
    .NET 4.0
    Join Date
    Sep 2012
    Location
    Healing, NE Lincs, UK
    Posts
    1,128
    Reputation
    743
    Hi,

    Go to Project on the Menu, Select Project Properties and change the Startup Form to your desired form.

    Hope that helps.

    Cheers,

    Ian

  3. #3
    Ace1000 is offline VB.NET Forum Newbie
    .NET Framework
    .NET 4.5
    Join Date
    Aug 2015
    Posts
    8
    Reputation
    0
    Thanks Ian.

    I don't know why I didn't think of that.

    Is there another method that you know of that does not require changing Form5 to the default Startup Form?
    I was so used to the world of MS Access where you can open any form you want.

    Thanks

  4. #4
    IanRyder is offline VB.NET Forum All-Mighty
    .NET Framework
    .NET 4.0
    Join Date
    Sep 2012
    Location
    Healing, NE Lincs, UK
    Posts
    1,128
    Reputation
    743
    Hi,

    Not really and I am not sure what the point or the benefit would be. Whichever Form you choose you need an Application Entry Point which is a Form in a Windows Forms Application.

    Cheers,

    Ian

  5. #5
    Ace1000 is offline VB.NET Forum Newbie
    .NET Framework
    .NET 4.5
    Join Date
    Aug 2015
    Posts
    8
    Reputation
    0
    I came from Access/VBA background where the configuration holds a single form as default and you can pretty much open any form in design or open mode without any configuration change.
    I am testing a lot of different mini code snippets for learning purposes in numerous forms.
    It's not too much work to change the default form. So I can't complain.

Tags for this Thread

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •