+ Reply to Thread
Results 1 to 6 of 6

Open MS Word Save Dialog From Excel VBA

  1. #1
    Registered User
    Join Date
    01-16-2014
    Location
    London, England
    MS-Off Ver
    Office 365
    Posts
    25

    Open MS Word Save Dialog From Excel VBA

    Hi All,

    I'm hoping this will be just a quick query with a simple answer. I have searched elsewhere online but haven't been able to find a solution.

    I have created a macro which creates a word document from a template, and populates the document with data from my excel sheet.

    What I would like is that when the macro is ran, once the word document appears on the screen, the Save As Dialog box opens allowing me to save the word document. I know that it's fairly straight forward to do this within excel, i.e. if you wanted to save the excel workbook, but I wouldn't know where to start in getting it to call the MS Word Save As dialog.

    Any help would be greatly appreciated.

    Many thanks in advance.
    Last edited by Skins11; 02-01-2016 at 02:31 PM.

  2. #2
    Forum Contributor
    Join Date
    09-03-2015
    Location
    IE
    MS-Off Ver
    2003 - 2016
    Posts
    258

    Re: Open MS Word Save Dialog From Excel VBA

    Why not go record a macro in Word while you click the Word SaveAs menu, then move the genereated code into your Excel code...? There will only be minor changes but the concept is exactly the same as writing Excel VBA code.

  3. #3
    Registered User
    Join Date
    01-16-2014
    Location
    London, England
    MS-Off Ver
    Office 365
    Posts
    25

    Re: Open MS Word Save Dialog From Excel VBA

    Thanks for the suggestion.

    I have just tried this but it doesn't show the code for opening the save as dialog, only for how the file was saved. If I was to use this, it would save the document; however I would like it to open the save as dialog so that the user can select the name and location.

    When I recorded the macro it gave me the following code:

    Please Login or Register  to view this content.
    Many thanks.

  4. #4
    Forum Contributor
    Join Date
    09-03-2015
    Location
    IE
    MS-Off Ver
    2003 - 2016
    Posts
    258

    Re: Open MS Word Save Dialog From Excel VBA

    Exactly the same as Excel... you just need the right dialog.

    This assumes you have an object named oWD which is a valid reference to an instance of Word.
    Please Login or Register  to view this content.
    It's only a dialog - doe snot save. You need to code for that.

  5. #5
    Registered User
    Join Date
    01-16-2014
    Location
    London, England
    MS-Off Ver
    Office 365
    Posts
    25

    Re: Open MS Word Save Dialog From Excel VBA

    I'm sorry, I'm failing to get this to work. A stripped down version of my code is as below - how would I apply your code to that?

    Please Login or Register  to view this content.
    Thanks again.

  6. #6
    Registered User
    Join Date
    01-16-2014
    Location
    London, England
    MS-Off Ver
    Office 365
    Posts
    25

    Re: Open MS Word Save Dialog From Excel VBA

    Okay, so I managed to figure it out. I'm fairly new to all of this, so I spend a lot of time fiddling and trying out before I get things to work, but the below seems to have done the trick.

    Please Login or Register  to view this content.
    I wasn't typing "Word" before application and so it was opening the Save As window in Excel.

    Thanks Grimes for taking the time to review.

    Skins

+ 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. [SOLVED] VBA Open Save As Dialog
    By hobbiton73 in forum Excel Programming / VBA / Macros
    Replies: 9
    Last Post: 04-23-2015, 01:37 AM
  2. Duplicate Save As Dialog - Word To PDF
    By bssm in forum Word Programming / VBA / Macros
    Replies: 3
    Last Post: 03-15-2015, 10:37 AM
  3. IE Open-Save As-Cancel Dialog Box
    By cabroncito29 in forum Excel Programming / VBA / Macros
    Replies: 1
    Last Post: 02-13-2015, 05:34 PM
  4. Open Word SaveAs dialog from Excel VBA
    By simonc2 in forum Excel Programming / VBA / Macros
    Replies: 6
    Last Post: 05-20-2013, 12:35 PM
  5. Open and Save Word Documents via Excel
    By abousetta in forum Excel Programming / VBA / Macros
    Replies: 8
    Last Post: 06-22-2010, 02:54 PM
  6. Microsoft Word VBA Open Dialog
    By joe41 in forum Word Programming / VBA / Macros
    Replies: 0
    Last Post: 03-10-2009, 01:53 AM
  7. [SOLVED] save file:open up a dialog
    By newbie in forum Excel Programming / VBA / Macros
    Replies: 3
    Last Post: 05-18-2005, 11:06 AM

Tags for this Thread

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