Printing Problem
Hi there,
I'm trying to print an ms word file using vb. Before it will go to printer, I want the document file to be viewable but not editable. Can anyone help me.
Thanks,
Note: I was able to view the doc file but it is editable. I am using ms word 8.0 object library.
Newvbguy
NewVBguy
Junior Poster in Training
71 posts since Mar 2005
Reputation Points: 13
Solved Threads: 3
Hi,
Thanks for your response but i just got the solution of my problem.
Cheers!!
Newvbguy
NewVBguy
Junior Poster in Training
71 posts since Mar 2005
Reputation Points: 13
Solved Threads: 3
Hi,
Thanks for your response but i just got the solution of my problem.
Cheers!!
Newvbguy
If it's not a bother, would you mind posting how you went about accomplishing this task?
Comatose
Taboo Programmer
2,910 posts since Dec 2004
Reputation Points: 361
Solved Threads: 215
If it's not a bother, would you mind posting how you went about accomplishing this task?
Hi,
This is a simple sample:
Private Sub Command1_Click()
Dim objWord As Word.Application
Set objWord = New Word.Application
objWord.Visible = True
objWord.Documents.Open "z:\test2.doc", , True, False
objWord.PrintPreview = True
objWord.WindowState = wdWindowStateMaximize
objWord.ShowMe
End Sub
NewVBguy
Junior Poster in Training
71 posts since Mar 2005
Reputation Points: 13
Solved Threads: 3
I Certainly appreciate the update. Now I have this in my bag of tricks of the future :)
Comatose
Taboo Programmer
2,910 posts since Dec 2004
Reputation Points: 361
Solved Threads: 215