+ Reply to Thread
Results 1 to 4 of 4

Disable form from opening @ workbook opening

  1. #1
    Forum Contributor
    Join Date
    04-20-2017
    Location
    Iowa
    MS-Off Ver
    2007
    Posts
    212

    Disable form from opening @ workbook opening

    I have created a workbook such that when a user opens it they are asked to enter job information before saving as a copy.

    Now I want to have another command button that will open the master workbook, update particular ranges, then save and close. However, it would be ideal if the user didn't need to exit the job information form when this happens.

    What statement can I write that will tell that form to either not appear, or cancel itself without user interaction?

    Thanks for any and all ideas.

  2. #2
    Forum Guru xlnitwit's Avatar
    Join Date
    06-27-2016
    Location
    London
    MS-Off Ver
    Windows: 2010; Mac: 16.13 (O365)
    Posts
    7,085

    Re: Disable form from opening @ workbook opening

    Hi,

    If the form is opened by the Workbook_Open event, you can disable that using
    Please Login or Register  to view this content.
    before opening the workbook in code; then reset the value to True after opening it. If you are using an Auto_Open routine, you do not need to do anything as that will not run when you open a workbook in code.
    Don
    Please remember to mark your thread 'Solved' when appropriate.

  3. #3
    Forum Contributor
    Join Date
    04-20-2017
    Location
    Iowa
    MS-Off Ver
    2007
    Posts
    212

    Re: Disable form from opening @ workbook opening

    Thank you so much. This sounds exactly like what I want.

    I'll let everyone know when I get it checked.

  4. #4
    Forum Contributor
    Join Date
    04-20-2017
    Location
    Iowa
    MS-Off Ver
    2007
    Posts
    212

    Re: Disable form from opening @ workbook opening

    After a little effort this works exactly as I want. The first attempt didn't work only because I only added the False statement to see if it would bypass the form, and the form still appeared.

    Even if there is no code between the two statements, the False & True lines must both be there.

    Thank You

+ Reply to Thread

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Similar Threads

  1. Disable the DELETE KEY and BACKSPACE key code on opening a workbook.
    By hans302 in forum Excel Programming / VBA / Macros
    Replies: 4
    Last Post: 01-05-2017, 11:30 PM
  2. Replies: 1
    Last Post: 01-05-2017, 05:02 PM
  3. Opening a Workbook using a MsgBox, and opening another message box on close
    By Henk12 in forum Excel Programming / VBA / Macros
    Replies: 1
    Last Post: 07-13-2015, 01:17 PM
  4. How to disable application alerts On workbook opening!
    By Korjaaja in forum Excel Programming / VBA / Macros
    Replies: 6
    Last Post: 08-08-2014, 12:11 PM
  5. Macro to Disable to close workbook after opening if machine ID doesnt mactch!
    By Taislin in forum Excel Programming / VBA / Macros
    Replies: 0
    Last Post: 12-11-2012, 10:07 PM
  6. [SOLVED] Can a form be opened without opening up/displaying the workbook?
    By amhulli in forum Excel Programming / VBA / Macros
    Replies: 11
    Last Post: 10-01-2012, 01:44 PM
  7. Opening Excel Application before Opening Workbook
    By danny2000 in forum Access Tables & Databases
    Replies: 2
    Last Post: 05-27-2011, 07:02 AM

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts

Search Engine Friendly URLs by vBSEO 3.6.0 RC 1