Select .Net 3.5 Framework
Using prn As New PrintDocument
With prn
.PrinterSettings.PrinterName = "Microsoft XPS Document Writer"
.DefaultPageSettings.PaperSize = New PaperSize("Legal", 850, 1400)
If My.Computer.FileSystem.FileExists(xpsfile) Then My.Computer.FileSystem.DeleteFile(xpsfile)
.DefaultPageSettings.PrinterSettings.PrintToFile = True
.DefaultPageSettings.PrinterSettings.PrintFileName = xpsfile
.Print()
End With
End Using
Add ReferenceWith prn
.PrinterSettings.PrinterName = "Microsoft XPS Document Writer"
.DefaultPageSettings.PaperSize = New PaperSize("Legal", 850, 1400)
If My.Computer.FileSystem.FileExists(xpsfile) Then My.Computer.FileSystem.DeleteFile(xpsfile)
.DefaultPageSettings.PrinterSettings.PrintToFile = True
.DefaultPageSettings.PrinterSettings.PrintFileName = xpsfile
.Print()
End With
End Using
ReachFramework
WindowBase
WindowBase
No comments:
Post a Comment