Can you create a word macro that has a choice for the user?

D

Danielle

I'd like to create a macro to insert a file into the existing document and
clean up clashes between the two, but i want the user to have the choice of
which file to insert, which is in the middle of the macro.
 
J

Jonathan West

Danielle said:
I'd like to create a macro to insert a file into the existing document and
clean up clashes between the two, but i want the user to have the choice
of
which file to insert, which is in the middle of the macro.

take a look at the MsgBox function in VBA help. You can have a yes/No choice
and branh according to which the user chooses.
 
H

heureux-oli

Hello

May be a idea

Dim oFD As FileDialog

Set oFD = Application.FileDialog(msoFileDialogOpen).Show
Debug.Print oFD.SelectedItems(1)

You will receive in the execution Windows the name and the path of the
selected file.
 

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