+ Reply to Thread
Results 1 to 6 of 6

How to press enter automatically when opening workbook

  1. #1
    Registered User
    Join Date
    10-10-2012
    Location
    Helsinki
    MS-Off Ver
    Excel 2010
    Posts
    9

    How to press enter automatically when opening workbook

    When I open my workbook, a pop-up window appears because my workbook contains links to other data sources. The "update" button is already selected and I would like to answer it automatically by pressing the enter key.

    I already have my Workbook_Open() macro, what is the code for pressing the enter key?

  2. #2
    Forum Contributor dogberry's Avatar
    Join Date
    07-15-2012
    Location
    Wales, UK
    MS-Off Ver
    Excel 2010
    Posts
    624

    Re: How to press enter automatically when opening workbook

    Sendkeys {ENTER}
    Hi

    Try the above

    Chris
    Click my star if I helped Thanks

  3. #3
    Registered User
    Join Date
    10-10-2012
    Location
    Helsinki
    MS-Off Ver
    Excel 2010
    Posts
    9

    Re: How to press enter automatically when opening workbook

    That doesn't work... Gives me only "invalid char" error...

  4. #4
    Forum Guru JosephP's Avatar
    Join Date
    03-27-2012
    Location
    Ut
    MS-Off Ver
    2003/10
    Posts
    7,328

    Re: How to press enter automatically when opening workbook

    the workbook open event will be too late for that. on the data tab choose edit links, then click the startup prompt button and choose the last option.
    Josie

    if at first you don't succeed try doing it the way your wife told you to

  5. #5
    Registered User
    Join Date
    10-10-2012
    Location
    Helsinki
    MS-Off Ver
    Excel 2010
    Posts
    9

    Re: How to press enter automatically when opening workbook

    Ok, that works. Does it anyway update the workbook also?

  6. #6
    Forum Guru JosephP's Avatar
    Join Date
    03-27-2012
    Location
    Ut
    MS-Off Ver
    2003/10
    Posts
    7,328

    Re: How to press enter automatically when opening workbook

    yes-it updates without prompting

+ Reply to Thread

Thread Information

Users Browsing this Thread

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

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