Reply
 
Thread Tools Display Modes
  #1   Report Post  
Posted to microsoft.public.word.mailmerge.fields
JC
 
Posts: n/a
Default Programatically convert a .doc to a .tif

I need to convert a word .doc to a .tif.

I can do it programatically but dont know how to get the Document Image
Writer window closed.

Heres my code - after it runs, i'm left with the Microsoft Office Document
Imaging window showing my TIF. I dont want this displayed to the user.

______________________-
Dim objWordApp As New Word.Application
Dim sPrinter As String
Dim sSaveFile As String

objWordApp.Documents.Open filename:=sdocpath
sSaveFile = "Test.TIF"

With objWordApp
..Visible = False
sPrinter = .ActivePrinter
..ActivePrinter = "Microsoft Office Document Image Writer on NE00:"
' Convert to a TIF
..ActiveDocument.PrintOut OutputFileName:=sSaveFile
..ActivePrinter = sPrinter
End With
objWordApp.Quit

ConvertToTIF = sdocpath

_____________________

Thanks - Joan

  #2   Report Post  
Posted to microsoft.public.word.mailmerge.fields
Charles Kenyon
 
Posts: n/a
Default Programatically convert a .doc to a .tif

You might want to ask this in one of the vba newsgroups rather than in this
one which is about mailmerge.
--
Charles Kenyon

Word New User FAQ & Web Directory: http://addbalance.com/word

Intermediate User's Guide to Microsoft Word (supplemented version of
Microsoft's Legal Users' Guide) http://addbalance.com/usersguide

See also the MVP FAQ: http://word.mvps.org/FAQs/ which is awesome!

My criminal defense site: http://addbalance.com
--------- --------- --------- --------- --------- ---------
This message is posted to a newsgroup. Please post replies
and questions to the newsgroup so that others can learn
from my ignorance and your wisdom.


"JC" wrote in message
...
I need to convert a word .doc to a .tif.

I can do it programatically but dont know how to get the Document Image
Writer window closed.

Heres my code - after it runs, i'm left with the Microsoft Office Document
Imaging window showing my TIF. I dont want this displayed to the user.

______________________-
Dim objWordApp As New Word.Application
Dim sPrinter As String
Dim sSaveFile As String

objWordApp.Documents.Open filename:=sdocpath
sSaveFile = "Test.TIF"

With objWordApp
.Visible = False
sPrinter = .ActivePrinter
.ActivePrinter = "Microsoft Office Document Image Writer on NE00:"
' Convert to a TIF
.ActiveDocument.PrintOut OutputFileName:=sSaveFile
.ActivePrinter = sPrinter
End With
objWordApp.Quit

ConvertToTIF = sdocpath

_____________________

Thanks - Joan



Reply
Thread Tools
Display Modes

Posting Rules

Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
URGENT - convert file to .pdf or .tif or .eps me2k3ow Microsoft Word Help 4 May 23rd 06 04:45 PM
How do I convert .pdf files to .doc files and .p65 to .pdf files D Burton Page Layout 2 April 2nd 06 07:25 AM
convert from .doc to WPD Orianna Microsoft Word Help 3 March 27th 06 06:59 AM
How can I convert an AppleWorks .cwk file to an MS Word .doc file. Padragine Microsoft Word Help 2 March 14th 05 02:21 AM


All times are GMT +1. The time now is 02:07 AM.

Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
Copyright ©2004-2024 Microsoft Office Word Forum - WordBanter.
The comments are property of their posters.
 

About Us

"It's about Microsoft Word"