The Shed is going Social! Join us on FaceBook and Twitter and chime in on the conversation.
|
 |
|
Dev Shed Forums
> Programming Languages - More
> ColdFusion Development
|
cold fusion printing
Discuss cold fusion printing in the ColdFusion Development forum on Dev Shed. cold fusion printing ColdFusion Development forum discussing CFML coding practices, tips on CFML, and other CFML related topics. Find out why ColdFusion is the tool of choice for many e-commerce developers.
|
|
 |
|
|
|
|

Dev Shed Forums Sponsor:
|
|
|

July 22nd, 2003, 11:21 AM
|
|
Junior Member
|
|
Join Date: Jul 2003
Posts: 3
Time spent in forums: < 1 sec
Reputation Power: 0
|
|
|
cold fusion printing
I need a script, function, anything that will do the following:
upon a button being pushed it makes a server call generating some data to be printed. It will then generate a form (hidden and completely unseen by the user), prints it and returns to its normal state. The real problem is I need it to print client-side rather than server-side. Any ideas would be much appreciated!!!
|

July 22nd, 2003, 04:45 PM
|
 |
Hello World :)
|
|
Join Date: Mar 2003
Location: Hull, UK
|
|
Hi Jediwheatie,
unfortuantly I dont think its possible with CF. Because CF is a server side utility it can't really get access to a clients printer, if you could that would be a really bad idea. Think about all the ad's you would get punted through.. You can do it with Javascript, the printer box will apear asking the user if they want to print or not.
It's a very long shot but maybe you could open a socket to the client's machine and send the data directly to the printer, but then i wouldn't know where to start. You'd also have to worry about things like OS and etc.
I'd stick to javascript and use the print function for this.
Hope this helps,
Mark.
|

July 22nd, 2003, 07:21 PM
|
|
Junior Member
|
|
Join Date: Jul 2003
Posts: 3
Time spent in forums: < 1 sec
Reputation Power: 0
|
|
|
Unfortunately however, javascript doesn't have the functions that I am requiring, unless of course, I don't know as much Javascript is as required. I need to click a button, make a coldfusion server call, return to the same page, and while that is happening, some script or anything to print something to a printer(never seen on screen). Anytime you generate a window and try to close it, it will then ask "The browser you are currently using is trying to be closed, Is this ok?" which I cannot have as a security risk. Let me know if you know any javascript functions to allow this type of functionality.
|

July 23rd, 2003, 06:01 AM
|
 |
Hello World :)
|
|
Join Date: Mar 2003
Location: Hull, UK
|
|
 you don't need to know much Javascript. maybe i didnt explane very well. use CF to generate your new page with a print function set to print OnLoad, the page will then be printed when it's done loading (with the users ok).
The rest I have no dout you can and should be do with CF, all I was trying to say what that CF cant access the printer, you need Javascript to do this for you.
Take care,
Mark.
|

July 23rd, 2003, 11:20 AM
|
|
Junior Member
|
|
Join Date: Jul 2003
Posts: 3
Time spent in forums: < 1 sec
Reputation Power: 0
|
|
|
thanks.
|

July 23rd, 2003, 11:27 AM
|
 |
Hello World :)
|
|
Join Date: Mar 2003
Location: Hull, UK
|
|
Very welcome Jedi, if you need any help i'd be happy to. I dont know much CF though  .
Mark.
|
Developer Shed Advertisers and Affiliates
| Thread Tools |
Search this Thread |
|
|
|
| Display Modes |
Rate This Thread |
Linear Mode
|
|
Posting Rules
|
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts
HTML code is Off
|
|
|
|
|