View Full Version : VBA to extract all images from word file

05-07-2013, 01:48 AM
Hi All,

I need a VBA code which will extract all the images from a word file and save that images into a a separate folder.

Please help me

05-07-2013, 02:25 AM
You don't need code, save your document as html page, a folder with all images will be created

05-07-2013, 03:28 AM


05-07-2013, 04:06 AM
Hi Patel,

I am totally agreed with your point but the problem is that while extracting in this way, the quality of pictures reduces, i mean to say it does not come up to its original dimension.

Our manager told to avoid that procedure.

See what i wanted is two buttons, one for extracting images and save it to some folder and another one to load the word file.

Means first load the word file from which we wants data and then extract the images.

Please help me:banghead:

05-07-2013, 05:56 AM
.... the quality of pictures reduces, i mean to say it does not come up to its original dimension.
are you sure ? what you see on word doc is not with original dimension.

Did you see the attached link on the previous post ?

05-07-2013, 06:55 AM
i checked the above link, its not working, please can u guide how to use,

I am in urgent use of it, please do the needfull.:friends:

05-07-2013, 07:55 AM
As you can see the code you can find on the attached link is not easy to understand from me and you, I think you have to follow the first method (save as html)

05-07-2013, 09:50 AM
please ask someone who have idea regarding this, and guide me. Thanks

05-07-2013, 10:46 AM
test attached document wih code in doc file

05-07-2013, 11:01 AM

Thanks a million sir its working ok no problem in it.

Truly speaking i am not able to understand the code , its not to my level. :)

Patel brother one more thing can be done or not like.
1) Images can be saved by the same name as it present in the doc file.
2) It will saves to one folder.

Thank you brother. Waiting for your reply:friends:

05-07-2013, 11:28 AM
as I said before, it's not my level also, the images have no name in word doc, then I can not save with present name.

2) It will saves to one folder - what do you mean ?

05-09-2013, 04:28 AM

See i have attached my word file which saves all the images in one folder.

Question i need to ask like is it possible to change the name of the images from "images001" to that whcih is just below the image.

For example in my attached doc, the first image name is "Screen shot 20: Group call Ready Page".

Can it be possible to give the same name while storing.

Please see my code. Guide me, i am very thankful.

05-09-2013, 06:47 AM
Patel ,

the doc file which you send me have code related to the dimensions of the pic,

How it works , how can i apply the same in my new attached file,

Please help me regd this.:banghead: