Results 1 to 2 of 2

Thread: Windows form with initial Visible property set to false?

  1. #1

    Thread Starter
    Frenzied Member conipto's Avatar
    Join Date
    Jun 2005
    Location
    Chicago
    Posts
    1,175

    Windows form with initial Visible property set to false?

    Hey, where did the Form.Visible property go in VB 2005? It's still there, but it doesn't show up in the properties window, and if I set it to false in the form's load event, the form still displays on startup? Anyone got a good workaround for this (hopefully without using a "main" module?)

    Bill
    Hate Adobe Acrobat? My Codebank Sumbissions - Easy CodeDom Expression evaluator: (VB / C# ) -- C# Scrolling Text Display

    I Like to code when drunk. Don't say you weren't warned.

  2. #2
    Super Moderator jmcilhinney's Avatar
    Join Date
    May 2005
    Location
    Sydney, Australia
    Posts
    111,222

    Re: Windows form with initial Visible property set to false?

    The Load event is raised the first time the form's Visible property is set to True, either directly or by calling Show. Setting the Visible property to False in the Load event handler doesn't really make sense. I guess the exception to this may be when you don't want your startup form to be visible because the app is to be minimised to the tray, or something like that. In that case just set the form to be minimised and not shown in the taskbar.
    Why is my data not saved to my database? | MSDN Data Walkthroughs
    VBForums Database Development FAQ
    My CodeBank Submissions: VB | C#
    My Blog: Data Among Multiple Forms (3 parts)
    Beginner Tutorials: VB | C# | SQL

Posting Permissions

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



Click Here to Expand Forum to Full Width