Results 1 to 5 of 5

Thread: Controlling the Loading and Display Of Forms

  1. #1

    Thread Starter
    New Member
    Join Date
    Apr 2007
    Posts
    15

    Controlling the Loading and Display Of Forms

    Good Morning

    What are the two methods and two statements that Visual Basic uses to control the loading and display of forms? This gets back to my issue of coming to grips with statements (code) and methods - the difference. Any advice welcome. Thanks. Mike.

  2. #2
    PowerPoster RhinoBull's Avatar
    Join Date
    Mar 2004
    Location
    New Amsterdam
    Posts
    24,132

    Re: Controlling the Loading and Display Of Forms

    Good evening!

    To load (and display) a form you can do use the Load or Show methods:
    Code:
    'to load Form2 from Form1
    Private Sub Command1_Click()
        'method 1
        Load Form2
        Form2.Visible = True
    
        'or method 2
        Form2.Show
    End Sub

  3. #3

    Thread Starter
    New Member
    Join Date
    Apr 2007
    Posts
    15

    Re: Controlling the Loading and Display Of Forms

    Thanks again Rhino much appreciated.

    Mike

  4. #4

  5. #5
    PowerPoster Simply Me's Avatar
    Join Date
    Aug 2003
    Posts
    2,748

    Re: Controlling the Loading and Display Of Forms

    When you use load the form is just loaded in memory and is not visible while when you use .show the form is loaded in memory and at the same time visible on screen.
    To give is always to be NOBLE...
    To received is always to be BLESSED....
    Each day strive to be NOBLE
    Each day strive to be BLESSED

    If this post has helped you. Please take time to rate it.

    >=|+|=< Simply Me >=|+|=<

    ----------------------------------------
    Connection Strings | Number Only in Textbox | Splash Screen with Progress Bar | Printing to 1/2 of perforated bond paper |
    Freeze 2005 DataGridView Column

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