Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations TouchToneTommy on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Word VBA macro - insert a file command, then pause 1

Status
Not open for further replies.

SNicholls

Technical User
May 13, 2004
22
US
In a Word 2003 macro, I want to create a macro to perform as follows:
open the Insert File dialog box
change to a specific drive/subdirectory
then stop so the user can browse to the appropriate file (which varies)
either end there or pause until the user finds the correct file and then resume with the Insert command (which closes the dialog box)
I can code to open the Open dialog box but not the Insert dialog box

When I used to create WordPerfect macros, there was a Pause command that would pause the macro until ENTER; anything like that in VBA?

Thanks.

SNicholls
 
I can code to open the Open dialog box but not the Insert dialog box
When you have the pathname choosen from the Open dialog box, play with the InsertFile method of the Range or Selection object.

Hope This Help, PH.
Want to get great answers to your Tek-Tips questions? Have a look at FAQ219-2884 or FAQ222-2244
 
Hi SNicholls,

Is this what you are looking for?

Code:
[blue]Application.Dialogs(wdDialogInsertFile).Show[/blue]

Enjoy,
Tony

--------------------------------------------------------------------------------------------
We want to help you; help us to do it by reading this: Before you ask a question.
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top