I want my program to open a word document and print it to the defulat printer without showing the printer box of commondialog. How should i do that? Right now i have:
Private Sub Print_Click()
CommonDialog1.Flags = cdlPDReturnDC + cdlPDNoPageNums
If choices.RTB1.SelLength = 0 Then
CommonDialog1.Flags = CommonDialog1.Flags + cdlPDAllPages
Else
CommonDialog1.Flags = CommonDialog1.Flags + cdlPDSelection
End If
Printer.DeviceName
CommonDialog1.ShowPrinter
Printer.Print ""
choices.RTB1.SelPrint CommonDialog1.hDC
End Sub
where, choices is my form; RTB1 is a richtextbox.
Thanks ~svn


Reply With Quote


Bookmarks