Hi Brother,
Just for your info,
I was trying for the samething last time and my requirement was to print
from server side..Means that I have a fixed printer with ip address and I use
Java print...This means When client click the print button ,it will come to
server and server will direc
Try putting the window.print() in the code for the page at urlx.
-Brian
On Sun, Feb 20, 2011 at 11:39 PM, @rju wrote:
>
> exactly i did
> but the problem here is.. see my code
>
> var urlx="myaction.action";
> var x= window.open(urlx);
> x.window.print();
>
> here it is invoking printer
> but
exactly i did
but the problem here is.. see my code
var urlx="myaction.action";
var x= window.open(urlx);
x.window.print();
here it is invoking printer
but empty page is printing because the action is taking time to load.
thats y am getting empty page so any alternative?
Brian Thompson-5 w
Then no, there's no way to do this.
What you *can* do is:
User clicks HTML button --> Struts action/Jasper report displays --> some
javascript on the report calls window.print(); --> user clicks "OK" on the
Print dialog.
-Brian
On Sun, Feb 20, 2011 at 10:27 PM, @rju wrote:
>
> yes user is c
yes user is clicking html/jsp button only
Brian Thompson-5 wrote:
>
> Where is the user clicking "ok"? Do you mean an HTML button? Or the
> browser's print dialog box?
>
> At the very least, the user will see the print dialog...there's no way
> around that for a web page (which, ultimately, i
Where is the user clicking "ok"? Do you mean an HTML button? Or the
browser's print dialog box?
At the very least, the user will see the print dialog...there's no way
around that for a web page (which, ultimately, is what Struts is sending to
the user).
-Brian
On Sun, Feb 20, 2011 at 9:46 PM
no sir.
no. user interaction means he will press ok button.
there "no user interaction" means after clicking "ok", some guys suggested
me that use onLoad () then write one listener for print. so here no user
interaction means after pressing ok button.
user will interact only by pressing ok button
server side:
write a file to a temp folder you can access ..preferably a folder that struts
already has mapped e.g.
setup a cron job which scans the struts mapped folder (on some pre-scribed
interval) and prints the contents (then deletes the file)
as mentioned executing print functionality is
If this is for an internal application for your company, you may be able to
use the Java Print API and print from the server, but as everyone else has
mentioned, you cannot have the browser start a print job without user
interaction. You can use the JavaScript window.print() function to bring up
t
On Sun, Feb 20, 2011 at 10:18 AM, Dave Newton wrote:
> I have no idea. Personally, I'd be a little surprised if it was
> possible to print from a website with *no* user interaction without
> using something like ActiveX, an applet, or *something*.
>
> Dave
>
>
Indeed. Browsers restrict such fun
I have no idea. Personally, I'd be a little surprised if it was
possible to print from a website with *no* user interaction without
using something like ActiveX, an applet, or *something*.
Dave
On Sun, Feb 20, 2011 at 11:06 AM, @rju wrote:
>
> sir please help me
> i ve already told my requiremen
sir please help me
i ve already told my requirement as follows
am using struts2-jasper plugin am calling my action through jquery.
nw i need to print the report directly from printer when i ve pressed ok
button.
ok button will call the action.
please help me ragarding this.Its very urgent for me a
sir please help me
i ve already told my requirement as follows
am using struts2-jasper plugin am calling my action through jquery.
nw i need to print the report directly from printer when i ve pressed ok
button.
ok button will call the action.
please help me ragarding this.Its very urgent for me a
13 matches
Mail list logo