Wrox Programmer Forums

Need to download code?

View our list of code downloads.

Go Back   Wrox Programmer Forums > ASP.NET and ASP > ASP 3 Classic ASP Active Server Pages 3.0 > Classic ASP Professional
Password Reminder
Register
| FAQ | Members List | Calendar | Search | Today's Posts | Mark Forums Read
Classic ASP Professional For advanced coder questions in ASP 3. NOT for ASP.NET 1.0, 1.1, or 2.0.
Welcome to the p2p.wrox.com Forums.

You are currently viewing the Classic ASP Professional section of the Wrox Programmer to Programmer discussions. This is a community of tens of thousands of software programmers and website developers including Wrox book authors and readers. As a guest, you can read any forum posting. By joining today you can post your own programming questions, respond to other developers’ questions, and eliminate the ads that are displayed to guests. Registration is fast, simple and absolutely free .
DRM-free e-books 300x50
Reply
 
Thread Tools Search this Thread Display Modes
  #1 (permalink)  
Old March 23rd, 2009, 02:48 PM
Authorized User
Points: 483, Level: 7
Points: 483, Level: 7 Points: 483, Level: 7 Points: 483, Level: 7
Activity: 0%
Activity: 0% Activity: 0% Activity: 0%
 
Join Date: Apr 2007
Location: Edgewood, NY, USA.
Posts: 92
Thanks: 0
Thanked 0 Times in 0 Posts
Default Print to an LPT1 printer from asp page?

Hello All.
I am looking to have my .asp page print into my adobe PDF print driver that resides on its server so I can create pdf files from my page that is a purchase order.

I can create a document that can create a word.doc, put I now am looking to send that text into my adobe print driver. Any ideas what the code would like? I dont have a clue where to start.

I have searched hi and low. Thanks!
Reply With Quote
  #2 (permalink)  
Old March 23rd, 2009, 03:36 PM
Friend of Wrox
 
Join Date: Jun 2008
Location: Snohomish, WA, USA
Posts: 1,649
Thanks: 3
Thanked 141 Times in 140 Posts
Default

Well, there's a product called "ASPPDF" that might be what you are looking for. Not sure whether it has a command to print to the local [which would of course be the server-local] printer, but worth looking into.

Not to ask a silly question, but if you are able to produce a WORD .doc file, why not just print that??
Reply With Quote
  #3 (permalink)  
Old March 23rd, 2009, 03:57 PM
Authorized User
Points: 483, Level: 7
Points: 483, Level: 7 Points: 483, Level: 7 Points: 483, Level: 7
Activity: 0%
Activity: 0% Activity: 0% Activity: 0%
 
Join Date: Apr 2007
Location: Edgewood, NY, USA.
Posts: 92
Thanks: 0
Thanked 0 Times in 0 Posts
Default

I am using FSO so employees can view the created files in a pulldown and open them. We get issues when they try to open a word doc in web browser. PDF would be a better option.
Reply With Quote
  #4 (permalink)  
Old March 23rd, 2009, 07:56 PM
Friend of Wrox
 
Join Date: Jun 2008
Location: Snohomish, WA, USA
Posts: 1,649
Thanks: 3
Thanked 141 Times in 140 Posts
Default

Ummm...you can't use FSO to send either .doc or .pdf files from server to browser. FSO only handles *TEXT* files. You have to use ADODB.Stream to send binary files, which is what both .doc and .pdf files are.

But maybe you need to show some code.
Reply With Quote
  #5 (permalink)  
Old May 29th, 2009, 02:11 PM
J_P J_P is offline
Authorized User
Points: 48, Level: 1
Points: 48, Level: 1 Points: 48, Level: 1 Points: 48, Level: 1
Activity: 0%
Activity: 0% Activity: 0% Activity: 0%
 
Join Date: May 2009
Posts: 12
Thanks: 0
Thanked 1 Time in 1 Post
Default what issues ?

printing is a client side action, ASP runs on the server.

unless the user has word or a pdf viewer they won't be able to see/print the files.
Reply With Quote
  #6 (permalink)  
Old May 31st, 2009, 02:25 AM
Friend of Wrox
 
Join Date: Jun 2008
Location: Snohomish, WA, USA
Posts: 1,649
Thanks: 3
Thanked 141 Times in 140 Posts
Default

(1) Why are you answering a post that is more than 2 months old?

(2) Read again what the original poster wanted. He wants to use ASP to "print" to a PDF *FILE*, not directly to a printer. And THEN he allows the user to download the PDF file. This is a quite reasonable thing to do; there are several free "print to PDF" drivers out there. You go into most any program (e.g., Word, or even Notepad) and select PRINT and then select the PDF Printer instead of a normal printer. The driver gives you a choice of what file name to print to and produces a ready-to-download PDF file. The problem: Selecting that PDF Printer from something like MS Word requires some pretty hefty "scripting" of the "application/msword" object. Non-trivial.

(3) If you know any Luddites who still don't have a PDF viewer (namely, Acrobat Reader) installed on their machines, tell them to move out of the Stone Age and stop using clay tablets to write on. And don't forget that you can save a Word document as ".rtf" which means that virtually any word processing program can read it, even those on Mac's and Linux machines.
Reply With Quote
  #7 (permalink)  
Old May 31st, 2009, 12:40 PM
J_P J_P is offline
Authorized User
Points: 48, Level: 1
Points: 48, Level: 1 Points: 48, Level: 1 Points: 48, Level: 1
Activity: 0%
Activity: 0% Activity: 0% Activity: 0%
 
Join Date: May 2009
Posts: 12
Thanks: 0
Thanked 1 Time in 1 Post
Default

Quote:
Originally Posted by Old Pedant View Post
(1) Why are you answering a post that is more than 2 months old?
why do you care ? it's not your post, it's not your forum.

Quote:
(2) Read again what the original poster wanted. He wants to bla bla bla....
let him speak for himself, you're not his mommy.

Quote:
(3) If you know any Luddites , bla bla bla...
just one.
Reply With Quote
Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off
Trackbacks are Off
Pingbacks are On
Refbacks are Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
get the printer name chosen in print dialog deep_ocean Classic ASP Basics 0 March 14th, 2007 10:27 AM
print page in ASP palu_2702 Classic ASP Basics 0 May 3rd, 2005 02:47 AM
Print From ASP Page arnabghosh Classic ASP Basics 0 April 19th, 2005 05:25 AM
printer.print problem rajanikrishna Pro VB 6 5 December 13th, 2004 10:25 PM
VB Printer.print command Hiddenattractor Java GUI 3 December 30th, 2003 09:08 AM



All times are GMT -4. The time now is 08:56 AM.


Powered by vBulletin®
Copyright ©2000 - 2019, Jelsoft Enterprises Ltd.
© 2013 John Wiley & Sons, Inc.