Results 1 to 10 of 10
  1. #1
    BertBruggeman is offline Novice
    Windows 10 Access 2016
    Join Date
    May 2021
    Posts
    5

    MS-Access Forms showing in background instead in front

    Hello,

    Our VBA MS-Access application uses forms.
    Sometimes when a new form is opened, its appears behind the current open forms.
    I googled about this and tried using BringWindowToTop and SetForegroundWindow, but so far no luck.
    Anybody who knows why this happens, and if there is a solution?



  2. #2
    ranman256's Avatar
    ranman256 is offline VIP
    Windows Vista Access 2010 32bit
    Join Date
    Apr 2014
    Location
    Kentucky
    Posts
    9,525
    Is the current form (before you open the new one) in MODAL mode?

  3. #3
    Bob Fitz's Avatar
    Bob Fitz is offline Access Developer
    Windows 10 Access 2016
    Join Date
    May 2011
    Location
    Essex UK
    Posts
    3,543
    Sometimes when a new form is opened, its appears behind the current open forms.
    Perhaps the first form opened has it's PopUp property set to Yes
    If this helped, please click the star at the bottom left of this posting and add to my reputation . Many thanks.
    Bob Fitzpatrick

  4. #4
    BertBruggeman is offline Novice
    Windows 10 Access 2016
    Join Date
    May 2021
    Posts
    5

    more info

    yes both modal as popup are set to true for all forms.
    And on some computers they show most of the times.. but unfortunately on some computer almost never.

  5. #5
    Minty is offline VIP
    Windows 10 Office 365
    Join Date
    Sep 2017
    Location
    UK - Wiltshire
    Posts
    3,003
    A Modal or Pop up form will remain on top of all others, unless something on that form opens another modal or popup form.
    A modal form retains the focus until it is closed or another modal form is opened from it.

    So the order they appear should be determined by the properties they are opened with.
    DLookup Syntax and others http://access.mvps.org/access/general/gen0018.htm
    Please use the star below the post to say thanks if we have helped !
    ↓↓ It's down here ↓↓

  6. #6
    BertBruggeman is offline Novice
    Windows 10 Access 2016
    Join Date
    May 2021
    Posts
    5
    Quote Originally Posted by Minty View Post
    A Modal or Pop up form will remain on top of all others, unless something on that form opens another modal or popup form.
    A modal form retains the focus until it is closed or another modal form is opened from it.

    So the order they appear should be determined by the properties they are opened with.
    But both modal/popup are set to true for all forms, and normally they just show in front.
    In past it worked almost most of the times, but now last weeks we got many people complaining.
    So i thought maybe someone knows a truc to bring it to front, when normal open fails.
    Or can tell me why it happens.

  7. #7
    Bob Fitz's Avatar
    Bob Fitz is offline Access Developer
    Windows 10 Access 2016
    Join Date
    May 2011
    Location
    Essex UK
    Posts
    3,543
    But both modal/popup are set to true for all forms, and normally they just show in front.
    Are they opened by using a button on the last form that was opened?
    If not, describe what the user does to open the form.
    If this helped, please click the star at the bottom left of this posting and add to my reputation . Many thanks.
    Bob Fitzpatrick

  8. #8
    BertBruggeman is offline Novice
    Windows 10 Access 2016
    Join Date
    May 2021
    Posts
    5
    Yes indeed, except for the first form start through macro, all forms are opened by a button on the top/active form.

  9. #9
    Bob Fitz's Avatar
    Bob Fitz is offline Access Developer
    Windows 10 Access 2016
    Join Date
    May 2011
    Location
    Essex UK
    Posts
    3,543
    Quote Originally Posted by BertBruggeman View Post
    Yes indeed, except for the first form start through macro, all forms are opened by a button on the top/active form.
    Then, as Minty has already stated, they should open on top. If they don't open on top I would question if the Modal and PopUp properties are really set to Yes.
    Perhaps you could post a copy of the db for us to examine.
    If this helped, please click the star at the bottom left of this posting and add to my reputation . Many thanks.
    Bob Fitzpatrick

  10. #10
    BertBruggeman is offline Novice
    Windows 10 Access 2016
    Join Date
    May 2021
    Posts
    5
    Thanx all.. after optimizing some queries someone here made, everything works to seem better,, so i think this topic can be closed..

    and sorry i didn't read guideline good enough, asked same question on microsoft forum side, as i excepted to get slow response there, i googled acces forums, and got here. next time i will ask here.

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

Similar Threads

  1. Replies: 2
    Last Post: 09-08-2020, 01:34 AM
  2. Replies: 9
    Last Post: 09-27-2013, 01:14 PM
  3. Help Forms not showing up in access
    By SirDrums in forum Forms
    Replies: 1
    Last Post: 02-08-2012, 05:16 PM
  4. Using external forms as report background
    By mperron in forum Reports
    Replies: 4
    Last Post: 01-05-2012, 03:32 PM
  5. Replies: 12
    Last Post: 06-16-2011, 01:35 PM

Tags for this Thread

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