locked
Form text messsage not displayed when database first opened RRS feed

  • Question

  • The text on the form that automatically opens when the database is opened does not display when the form is opened but does display any time after that if the form is opened again

    This form executes VBA code associated with the On Open event which does run

    I tried adding code to open another form that just displays text to the VBA code but that form also does not show initially. It does display if the code is run again

    The initialization process can take some time and I want to show a message to let users know that something is happening

    Thursday, July 12, 2018 10:04 PM

Answers

  • It does not work when the form is opened - the message is not displayed until Initialization is completed - but it does work subsequently if I close all forms then manually open the Initial_Screen form

    Hi,

    I don't understand. The file I downloaded does not work even if I close all the forms and manually open the Initial_Screen form.

    Here are the steps I took, see if you can duplicate my results:

    1. Deleted the Autoexec macro

    2. Go to Options and set the Display Form for Current Database to Initial_Screen

    3. Change the Open event of the form Intial_Screen to add DoEvents after the DoCmd.OpenForm line (as show in the image in my previous post)

    4. Close and reopen the database

    Hope it helps...

    • Marked as answer by BVitter Saturday, July 14, 2018 12:40 PM
    Saturday, July 14, 2018 2:06 AM

All replies

  • Hello BVitter,

    Have you ever used a macro to open a form while the database is opened? If it does, please share the macro.

    If not, please back up your database and remove unrelated objects and any sensitive documents and share the database for us to reproduce your issue.

    Best Regards,

    Terry


    MSDN Community Support
    Please remember to click "Mark as Answer" the responses that resolved your issue, and to click "Unmark as Answer" if not. This can be beneficial to other community members reading this thread. If you have any compliments or complaints to MSDN Support, feel free to contact MSDNFSF@microsoft.com.

    Friday, July 13, 2018 5:14 AM
  • I created a simple version of the database that shows the issue and uploaded it to OneDrive:

    The same issue happened whether I use an AutoExec Macro or an Initial Screen loaded when the database is opened

    The Daily Processing Message screen is not displayed until after processing logic runs even though it is opened before the logic in called

    https://1drv.ms/u/s!ApiVn_Y-_UimyGERYS9JqDji65Y_

    Friday, July 13, 2018 2:59 PM
  • Hi,

    All I did to fix the problem was modify your initial form's open code to add DoEvents. Give it a try and let us know how it goes...

    PS. Sorry, I don't know what is the equivalent action for your Autoexec macro.

    Hope it helps...

    Friday, July 13, 2018 3:13 PM
  • It does not work when the form is opened - the message is not displayed until Initialization is completed - but it does work subsequently if I close all forms then manually open the Initial_Screen form
    Friday, July 13, 2018 11:37 PM
  • It does not work when the form is opened - the message is not displayed until Initialization is completed - but it does work subsequently if I close all forms then manually open the Initial_Screen form

    Hi,

    I don't understand. The file I downloaded does not work even if I close all the forms and manually open the Initial_Screen form.

    Here are the steps I took, see if you can duplicate my results:

    1. Deleted the Autoexec macro

    2. Go to Options and set the Display Form for Current Database to Initial_Screen

    3. Change the Open event of the form Intial_Screen to add DoEvents after the DoCmd.OpenForm line (as show in the image in my previous post)

    4. Close and reopen the database

    Hope it helps...

    • Marked as answer by BVitter Saturday, July 14, 2018 12:40 PM
    Saturday, July 14, 2018 2:06 AM
  • Thank you, I apparently forgot to kill the AutoExec macro and that interfered with the Open Form action
    Saturday, July 14, 2018 12:41 PM
  • Hi,

    You're welcome. Glad to hear you got it sorted out. Good luck with your project.

    Saturday, July 14, 2018 2:26 PM