Results 1 to 4 of 4
  1. #1
    gerrymouse1 is offline Novice
    Windows XP Access 2003
    Join Date
    Apr 2011
    Posts
    4

    Open Form and Close Previous Form

    Hello,



    I have an opening form on my database just as a welcome and explanation about the database. I then have 2 buttons. One which aEnters the database and one which closes the Database.

    I am getting a bit picky and would like the opening window to close when the Enter Database button is clicked aswell as opening the Main Page form.

    Any help welcome.

    Thanks

    Gerry

  2. #2
    Rixxe is offline Blessed Bear
    Windows 7 Access 2007
    Join Date
    Sep 2010
    Location
    London (Essex ... yep!)
    Posts
    184
    Something like: (I don't know vba hardly so good luck!)


    To Open Form 2 and hide Form 1
    Me.Visible = False
    DoCmd.OpenForm "Form2", acNormal, , , acFormEdit, acWindowNormal

    Then make form 1 visable after form 2 is closed


    Private Sub Form_Close()
    Forms![frmTest].Visible = True
    End Sub

  3. #3
    gerrymouse1 is offline Novice
    Windows XP Access 2003
    Join Date
    Apr 2011
    Posts
    4
    Cheers,


    Never considered just making the form invisible. I did not have to make it visible again as the Database calls it on open.


    Thanks for your help!!

  4. #4
    Rixxe is offline Blessed Bear
    Windows 7 Access 2007
    Join Date
    Sep 2010
    Location
    London (Essex ... yep!)
    Posts
    184
    You are welcome

Please reply to this thread with any new information or opinions.

Similar Threads

  1. DAO.Recordsets - When to close and open
    By jgelpi16 in forum Programming
    Replies: 11
    Last Post: 02-08-2011, 09:16 AM
  2. Replies: 3
    Last Post: 10-22-2010, 06:53 PM
  3. Open Form with instance method & wait to close?
    By GeorgeBakoyannis in forum Forms
    Replies: 1
    Last Post: 10-09-2010, 11:00 AM
  4. Open Form with information from previous form
    By jheintz57 in forum Forms
    Replies: 9
    Last Post: 03-23-2010, 07:30 AM
  5. Replies: 4
    Last Post: 01-27-2010, 12:39 PM

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
Other Forums: Microsoft Office Forums