Lexius
Lexius

Reputation: 85

MS Access form disappearing when switching to Form view

I have a form that was working, then eventually when I go from Design view to Form view it just disappears, there are no errors and I cannot see it anywhere. The form is open, as I checked in the Immediate window with, Forms(0).Name

I tried: repairing the database. creating a new database and importing all the objects. copying the form, removing all the controls and code - then opening the form, and it still disappears.

version: Microsoft Access 365/2021, Version 16. Subscription version

Upvotes: 0

Views: 690

Answers (2)

Les Miazga
Les Miazga

Reputation: 1

If you are using multiple displays, then this may be the problem. Disconnect and reconnect additional displays and see if this resolves the issue.

Upvotes: 0

Gustav
Gustav

Reputation: 55806

  1. Save the form as text using this command:
SaveAsText acForm, "YourFormName", "C:\Test\YourFormName.txt"
  1. Rename the form in Access to, say, "YourFormName_old"

  2. Open the file with a text editor like Notepad and locate the Top and Left entries

  3. Set these to a low value, say 100:

Version =21
VersionRequired =20
PublishOption =1
Checksum =-1703185324
Begin Form
    PopUp = NotDefault
    DividingLines = NotDefault
    AllowDesignChanges = NotDefault
    DefaultView =0
    PictureAlignment =2
    DatasheetGridlinesBehavior =3
    GridY =10
    Width =2093
    DatasheetFontHeight =11
    ItemSuffix =2
    Left =100
    Top =100
    Right =15465
    Bottom =13815
    DatasheetGridlinesColor =14806254
  1. Save the file

  2. Load the form using this command:

LoadFromText acForm, "YourFormName", "C:\Test\YourFormName.txt"
  1. Open the form. It will display at top-left

Upvotes: 2

Related Questions