Displaying Insert/Picture dialog box

A

Adri

I need to display the Insert/Picture dialog box, pointing to a specific
directory. I can get the dialog to display, but can't figure out how to
change 'look in' to the directory I want. Any suggestions? I'm using:
Dialogs(wdDialogInsertPicture).Show to display the dialog.
 
D

Dave Lett

Hi Adri,

You can use something like the following:

Dim sPixFolder As String
''' store the default pictures location
sPixFolder = Options.DefaultFilePath(wdPicturesPath)
''' change the default pictures location
Options.DefaultFilePath(wdPicturesPath) = "C:\Test\"
''' open the dialog box
Dialogs(wdDialogInsertPicture).Show
''' restore the default pictures location
Options.DefaultFilePath(wdPicturesPath) = sPixFolder

HTH,
Dave
 
A

Adri

Thanks Dave, works perfectly.

Dave Lett said:
Hi Adri,

You can use something like the following:

Dim sPixFolder As String
''' store the default pictures location
sPixFolder = Options.DefaultFilePath(wdPicturesPath)
''' change the default pictures location
Options.DefaultFilePath(wdPicturesPath) = "C:\Test\"
''' open the dialog box
Dialogs(wdDialogInsertPicture).Show
''' restore the default pictures location
Options.DefaultFilePath(wdPicturesPath) = sPixFolder

HTH,
Dave
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top