Link to home
Start Free TrialLog in
Avatar of mdemint1
mdemint1

asked on

Can I use a macro to insert pictures from a folder into Word?

Basically, I have folders containing pictures that we downloaded from our camera.  We want to be able to insert all of the pictures in the folder to a word document.  We would also like to have the file name (path not necessary) pasted directly beneath it.

Is this possible?

It would be nice to have a message window pop up asking the user to paste the address of the folder.

Note:
The folders will only contain pictures.
It would be an added bonus to be able to scale the images... maybe by including the option in the same window as the address input box?
Avatar of Aj8787
Aj8787

Sub Macro3()
'
' Macro3 Macro
' Macro recorded 7/20/2006 by Delana Harper
'


With ActiveDocument.Bookmarks(1)

Selection.InlineShapes.AddPicture
FileName:="P:\dharper\GovOfficeTemplates\msoffice\signature\jer.jpg",
LinkToFile:= _
False, SaveWithDocument:=True

End With

End Sub
I had this macro working you can try it and see if it gives desired results
Avatar of mdemint1

ASKER

@Aj8787

Thanks, but this macro only inserts a single image.  What I am wanting is a macro that inserts every image in a folder.  The user should also be able to specify the address to the folder containing said pictures.
Check out the following link. I am not sure how much help you can get from here but yeah may be:

http://msdn.microsoft.com/en-us/magazine/cc507643.aspx

Later
ASKER CERTIFIED SOLUTION
Avatar of GrahamSkan
GrahamSkan
Flag of United Kingdom of Great Britain and Northern Ireland image

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
All I had to change was:

strFolder = InputBox("Enter Folder Location", "Folder Location", "X:\")

Thanks so much!!