Photo Gallery Member List Search Calendars FAQ Ticket List Log Out


Printing issue

 
Logged in as: Guest
arrSession:exec spGetSession 2,2,59830
 Active Users: There are 0 members and 0 guests.
 Users viewing this topic: none
 

 

 
  
  Printable Version
All Forums >> [Scripting] >> WSH & Client Side VBScript >> Printing issue
  Do you like VisualBasicScript.com? Link to us and help spread the word about our forum. Thanks!
Page: [1]
Login
Message << Older Topic   Newer Topic >>
 Printing issue - 5/5/2008 5:51:07 AM   
  trkghost

 

Posts: 20
Score: 0
Joined: 3/18/2008
Status: offline
Hello,
I am using the code below to send documents to a network printer.  I am doing this so that if we change the default printer on the server it will not interfere with the script I have set to run.  The problem I am encountering is that everytime it prints it is not fitting to the size of the page.  So the right side ends up getting cut off.  Is there a better way of doing this?  or is there a way for me to fix this?

Thank you,
Travis

quote:

Sub Main
   Dim FSO
   Set FSO = CreateObject("Scripting.FileSystemObject")
   FSO.CopyFile(C:\test\test.txt, \\network\printer)
End Sub
 
 
Post #: 1
 
 RE: Printing issue - 5/7/2008 3:52:28 PM   
  the_apostle21


Posts: 43
Score: 0
Joined: 7/29/2005
Status: offline
have you checked the printer settings?  you may have the wrong page layout, ie. Letter instead of A4.

(in reply to trkghost)
 
 
Post #: 2
 
 RE: Printing issue - 5/8/2008 5:42:11 AM   
  Rischip


Posts: 341
Score: 2
Joined: 3/26/2007
Status: online
What is the format is the document? Plain text, RTF, word, PDf, etc...... The answers could be different and the format matters. Also the printer settings do matter as the apostolic one said.

_____________________________

Rischip
Author of - The Grim Linker

(in reply to the_apostle21)
 
 
Post #: 3
 
 RE: Printing issue - 5/8/2008 5:52:58 AM   
  trkghost

 

Posts: 20
Score: 0
Joined: 3/18/2008
Status: offline
It is in a RPT format...which is basically the same as a TXT document.  The printer settings are okay, checked them.

(in reply to Rischip)
 
 
Post #: 4
 
 RE: Printing issue - 5/8/2008 6:37:39 AM   
  Rischip


Posts: 341
Score: 2
Joined: 3/26/2007
Status: online
Try this at a command prompt.

"%programfiles%\windows nt\accessories\wordpad.exe" /pt "document path and name.rpt" "\\server\sharedprinter"

_____________________________

Rischip
Author of - The Grim Linker

(in reply to trkghost)
 
 
Post #: 5
 
 
 
  

If you found our site useful please link to us <a href="http://www.visualbasicscript.com">VisualBasicScript.com</a>.
All Forums >> [Scripting] >> WSH & Client Side VBScript >> Printing issue Page: [1]
Jump to:





New Messages No New Messages
Hot Topic w/ New Messages Hot Topic w/o New Messages
Locked w/ New Messages Locked w/o New Messages
 Post New Thread
 Reply to Message
 Post New Poll
 Submit Vote
 Delete My Own Post
 Delete My Own Thread
 Rate Posts