Hi,
I am having a view problems with printing, When I hit command5 I get the word doc saying blank.doc is read only which it is not, also if I choose to open this doc it will be displayed when I have set visible to false, then when it prints it out I have 2 docs 1 saying "hello" in the specified positions and saying spooling which takes time, the other just the blank doc "blank.doc".
what I want is to read in blank.doc and put the text "hello" in a certain poistion without showing the doc.
lofttyCode:Private Sub Command5_Click() Set objWordApp = CreateObject("Word.Application") objWordApp.Visible = False Set objDestDoc = objWordApp.Documents.Add Set objWordDoc = objWordApp.Documents.Open("C:\Documents and Settings\loftty\Desktop\VB6\testdelete\testlistnew\blank.doc") objDestDoc.PrintOut objDestDoc.Close SaveChanges:=False Set objDestDoc = Nothing Set objWordDoc = Nothing End Sub




Reply With Quote