export/extract pictures from word??

M

matt

we REALLY need a way to export jpg images from word, and
specify the size and resolution of the exported file.
is there a way? an add-in? a third party program?

help!
thanks.
 
D

Doug Robbins - Word MVP

Here's some information that I received from a fellow MVP

Doug I have posted a Word document and a DOT Template on my Web site.
The two functions, SaveToBitmap and SaveToEnhancedMetafile are called
from a Custom Menu.
I've tested the code and everything seems to be working as expected.

I must say that after finishing all of this I'm a bit disappointed.
Tonight while performing final testing, I happened to use MS Photo
Editor to examine some of my exported Images. Just for fun, I went back
and copied directly from Word into Photo Ed. Well it worked. even on a
resized, embedded Image I was able to paste in the original Image at the
original size and resolution.
From reading the NG's I was lead to mistakenly believe that the only way
to export an embedded Image within a Word doc was to use the export to
HTML method with it's accompanying loss of resolution. Apparently I was
grossly mistaken.

Oh well, I've posted the solution I coded. It's at the top of the MISC
page here:
http://www.lebans.com/MISC.htm


--
Please post any further questions or followup to the newsgroups for the
benefit of others who may be interested. Unsolicited questions forwarded
directly to me will only be answered on a paid consulting basis.

Hope this helps
Doug Robbins - Word MVP
 
M

matt

hi doug...
hey thanks so much for looking into this, and working on
it. im not sure if im being stupid here, but im not
figuring out what to do from the word file/s you posted.
i open them, and see the picture... where is this Custom
Menu you speak of, to get the commands you coded?
ive checked a bunch of places...
what am i missing?
thanks again.
matt



-----Original Message-----
Here's some information that I received from a fellow MVP

Doug I have posted a Word document and a DOT Template on my Web site.
The two functions, SaveToBitmap and
SaveToEnhancedMetafile are called
 
S

Suzanne S. Barnhill

You have to create the custom menu yourself and put the commands (macros) on
it.
 
M

matt

hey this is a GREAT macro! i got it to work out of the
Macros... dialog box inside this document.
i also found how to throw up a new customized menu. i
havent found yet how to marry the new marco with the
overall menu, but i'll figure that much out. you guys
have helped me a ton...dont want to ask any more stupid
questions.

thanks so much for your expertise!!
matt
 
M

matt

got it!
i have a menu with the new macro included.
i'll just pass around this .dot file for people who need
to use it here. i appreciate it. this is so cool!

one last question, under the category of "pressing my
luck." this macro creates a bmp at 600 dpi, which is a
huge huffin' file. what would it take to create the same
thing with a jpg export option?

or, a bmp that gave you dpi output options, rather than
the default 600?

thanks again for your input.
matt
 
S

Stephen Lebans

The code I wrote creates the output size and resolution based on the
original file as it exists on your word document. I'll look at adding a
property to the class allowing you to set these variables.

The core of the class was taken from a class of mine that exports
embedded Images from an Access table to JPEG files. I left out the JPEG
interface because it relied on the INtell JPEG DLL that is no longer
available for redistribution or supported by Intel. I have lately been
using the Microsoft GDI+ DLL to save images to Jpeg and plan on adding
incorporating this method in this Word project to allow you to save the
Images to BMP, EMF, JPG, GIF or TIF files.

I consider this current version as a Beta release. There is no error
handling for the Word event model. I also I am having trouble even
releaseing a DOT file that incorporates the Custom Menu items and the
associated class/code modules. I really have never worked with Word
before.
Should be a new release in the next week barring any new projects
popping up.
:)
--

HTH
Stephen Lebans
http://www.lebans.com
Access Code, Tips and Tricks
Please respond only to the newsgroups so everyone can benefit.
 
G

Graham Mayor

Excellent - I have added a link to the web page from my own on this subject.

--
<>>< ><<> ><<> <>>< ><<> <>>< <>>< ><<>
Graham Mayor - Word MVP

Web site www.gmayor.com
Word MVP web site www.mvps.org/word
<>>< ><<> ><<> <>>< ><<> <>>< <>>< ><<>
 
M

matt

thanks so much! cant really figure out how you guys think
or do what you do, but im very appreciative! looking
forward to the next release!
 
M

matt

hi stephen.
just wondered if you had any more chance to work on your
sweet little macro for extracting jpgs from word.
thanks so much!
matt
 
S

Stephen Lebans

Sorry, I am trying to finish a compression project and it is taking me
longer than expected.
:-(

By the way, the solution should not be catagorized as a Macro. A Macro
expression is used to call a function, that instantiates the class, that
extracts the Image and finally saves it to disk.
I do not create Macros!<grin>
:)
--
HTH
Stephen Lebans
http://www.lebans.com
Access Code, Tips and Tricks
Please respond only to the newsgroups so everyone can benefit.
 
M

matt

gotcha.... thanks for the clarification.
no more macro talk.

whenever you get around to tinkering with the function-
calling class-instantiating image extractor, would you be
able to shoot me off a quick email (listed on this
message)? i appreciate your work.
 

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