By using this site, you agree to our updated Privacy Policy and our Terms of Use. Manage your Cookies Settings.
424,854 Members | 2,015 Online
Bytes IT Community
+ Ask a Question
Need help? Post your question and get tips & solutions from a community of 424,854 IT Pros & Developers. It's quick & easy.

Print the page without loading it

P: n/a
While not rs.eof
<td><%=rs("InvoiceNo")%></td>
<td><%=rs("Name")%></td>
<td><a href="InvoicePrint.asp?WInv=<%=rs("InvoiceNo")%>"> </a></td>
<td>Print this invoice</td>
rs.MoveNext
Wend

Now user needs to click the link to open the invoice, and then select
File--Print from the menu to print it out, and then return back to print
another. As the table is very long, they need to scroll again to find the
next one.

I want to make the user more comfortable, that they
simply click the "Print" button in the end of the row, without opening the
page, print the invoice no they want. Is it possible ?

Jul 22 '05 #1
Share this Question
Share on Google+
5 Replies


P: n/a
"Alan" <al**@neind.net> wrote in message
news:ON**************@TK2MSFTNGP10.phx.gbl...
While not rs.eof
<td><%=rs("InvoiceNo")%></td>
<td><%=rs("Name")%></td>
<td><a href="InvoicePrint.asp?WInv=<%=rs("InvoiceNo")%>"> </a></td>
<td>Print this invoice</td>
rs.MoveNext
Wend

Now user needs to click the link to open the invoice, and then select
File--Print from the menu to print it out, and then return back to print
another. As the table is very long, they need to scroll again to find the
next one.

I want to make the user more comfortable, that they
simply click the "Print" button in the end of the row, without opening the
page, print the invoice no they want. Is it possible ?


You could just open up the Invoice in a new window:

<a href="InvoicePrint.asp?WInv=<%=rs("InvoiceNo")%>" target="_blank"></a>

Also, you could educate your users to click the printer icon
(one of the Standard Buttons) rather than clicking File+Print.

If you do achieve silent printing I'd inform the user via an alert()
that an invoive print was performed; otherwise, they may click
repeatedly not knowing what's happening --
(as the printer may be located elsewhere).
Jul 22 '05 #2

P: n/a
Thanks for yr help, because my program run in full screen, thus no icon and
buttons, and I expected when the users click print, then a printer dialog
box appear, they can select which printer they want. So I still need the
answers. I tried to write in jscript, but don't work, I tried to post to
js.group, noone can answers, I search in Google, over hundred messages want
to do this, but no method, is it possible, or someone has another better way
to do this ?
"McKirahan" <Ne**@McKirahan.com> 级糶秎ン穝籇:Gt********************@comcast.com. ..
"Alan" <al**@neind.net> wrote in message
news:ON**************@TK2MSFTNGP10.phx.gbl...
While not rs.eof
<td><%=rs("InvoiceNo")%></td>
<td><%=rs("Name")%></td>
<td><a href="InvoicePrint.asp?WInv=<%=rs("InvoiceNo")%>"> </a></td>
<td>Print this invoice</td>
rs.MoveNext
Wend

Now user needs to click the link to open the invoice, and then select
File--Print from the menu to print it out, and then return back to print
another. As the table is very long, they need to scroll again to find the
next one.

I want to make the user more comfortable, that they
simply click the "Print" button in the end of the row, without opening
the
page, print the invoice no they want. Is it possible ?


You could just open up the Invoice in a new window:

<a href="InvoicePrint.asp?WInv=<%=rs("InvoiceNo")%>" target="_blank"></a>

Also, you could educate your users to click the printer icon
(one of the Standard Buttons) rather than clicking File+Print.

If you do achieve silent printing I'd inform the user via an alert()
that an invoive print was performed; otherwise, they may click
repeatedly not knowing what's happening --
(as the printer may be located elsewhere).

Jul 22 '05 #3

P: n/a
How about using a checkbox instead of a link in your table? Allow the user
to select the rows he wants to print, then click a single button outside the
table to print all the selected invoices? The button would submit to a page
that loads all the selected invoices, using window.print in the onload event
to bring up the print dialog.

Bob Barrows

Alan wrote:
Thanks for yr help, because my program run in full screen, thus no
icon and buttons, and I expected when the users click print, then a
printer
dialog box appear, they can select which printer they want. So I still
need
the answers. I tried to write in jscript, but don't work, I tried to
post to js.group, noone can answers, I search in Google, over hundred
messages want to do this, but no method, is it possible, or someone has
another
better way to do this ?
"McKirahan" <Ne**@McKirahan.com>
级糶秎ン穝籇:Gt********************@comcast.com. ..
"Alan" <al**@neind.net> wrote in message
news:ON**************@TK2MSFTNGP10.phx.gbl...
While not rs.eof
<td><%=rs("InvoiceNo")%></td>
<td><%=rs("Name")%></td>
<td><a
href="InvoicePrint.asp?WInv=<%=rs("InvoiceNo")%>"> </a></td>
<td>Print this invoice</td> rs.MoveNext
Wend

Now user needs to click the link to open the invoice, and then
select File--Print from the menu to print it out, and then return back
to
print another. As the table is very long, they need to scroll again to
find the next one.

I want to make the user more comfortable, that they
simply click the "Print" button in the end of the row, without
opening the
page, print the invoice no they want. Is it possible ?


You could just open up the Invoice in a new window:

<a href="InvoicePrint.asp?WInv=<%=rs("InvoiceNo")%>"
target="_blank"></a> Also, you could educate your users to click the
printer icon
(one of the Standard Buttons) rather than clicking File+Print.

If you do achieve silent printing I'd inform the user via an alert()
that an invoive print was performed; otherwise, they may click
repeatedly not knowing what's happening --
(as the printer may be located elsewhere).


--
Microsoft MVP - ASP/ASP.NET
Please reply to the newsgroup. This email account is my spam trap so I
don't check it very often. If you must reply off-line, then remove the
"NO SPAM"
Jul 22 '05 #4

P: n/a
Thanks, if open all the invoice in new windows, that means the user need to
close all the windows after finished. Meanwhile, I have try the window.print
onload event before, the result of course will open the invoice first, the
different is then show the print dialog box automatically, what I want is to
print the page in routine without loading it. I search hundred of message
from other websites about this issue, it seems very popular and many people
want to do this. I have download a "PrintHid.js" from microsoft.com, but it
can't work with ASP routine, since one is client-side and one is
server-side. I search for this answer for a long time, Can anyone help me.
"Bob Barrows [MVP]" <re******@NOyahoo.SPAMcom> 级糶秎ン穝籇:eW**************@tk2msftngp13.phx.g bl...
How about using a checkbox instead of a link in your table? Allow the user
to select the rows he wants to print, then click a single button outside
the table to print all the selected invoices? The button would submit to a
page that loads all the selected invoices, using window.print in the
onload event to bring up the print dialog.

Bob Barrows

Alan wrote:
Thanks for yr help, because my program run in full screen, thus no
icon and buttons, and I expected when the users click print, then a
printer
dialog box appear, they can select which printer they want. So I still
need
the answers. I tried to write in jscript, but don't work, I tried to
post to js.group, noone can answers, I search in Google, over hundred
messages want to do this, but no method, is it possible, or someone has
another
better way to do this ?
"McKirahan" <Ne**@McKirahan.com>
级糶秎ン穝籇:Gt********************@comcast.com. ..
"Alan" <al**@neind.net> wrote in message
news:ON**************@TK2MSFTNGP10.phx.gbl...
While not rs.eof
<td><%=rs("InvoiceNo")%></td>
<td><%=rs("Name")%></td>
<td><a
href="InvoicePrint.asp?WInv=<%=rs("InvoiceNo")%>"> </a></td>
<td>Print this invoice</td> rs.MoveNext
Wend

Now user needs to click the link to open the invoice, and then
select File--Print from the menu to print it out, and then return back
to
print another. As the table is very long, they need to scroll again to
find the next one.

I want to make the user more comfortable, that they
simply click the "Print" button in the end of the row, without
opening the
page, print the invoice no they want. Is it possible ?
You could just open up the Invoice in a new window:

<a href="InvoicePrint.asp?WInv=<%=rs("InvoiceNo")%>"
target="_blank"></a> Also, you could educate your users to click the
printer icon
(one of the Standard Buttons) rather than clicking File+Print.

If you do achieve silent printing I'd inform the user via an alert()
that an invoive print was performed; otherwise, they may click
repeatedly not knowing what's happening --
(as the printer may be located elsewhere).


--
Microsoft MVP - ASP/ASP.NET
Please reply to the newsgroup. This email account is my spam trap so I
don't check it very often. If you must reply off-line, then remove the
"NO SPAM"

Jul 22 '05 #5

P: n/a
No! I meant: open a single window with all the selected invoices displayed
in that window.

Alan wrote:
Thanks, if open all the invoice in new windows, that means the user
need to
close all the windows after finished. Meanwhile, I have try the
window.print
onload event before, the result of course will open the invoice
first, the
different is then show the print dialog box automatically, what I
want is to
print the page in routine without loading it. I search hundred of
message
from other websites about this issue, it seems very popular and many
people
want to do this. I have download a "PrintHid.js" from microsoft.com,
but it
can't work with ASP routine, since one is client-side and one is
server-side. I search for this answer for a long time, Can anyone
help me.
"Bob Barrows [MVP]" <re******@NOyahoo.SPAMcom>
级糶秎ン穝籇:eW**************@tk2msftngp13.phx.g bl...
How about using a checkbox instead of a link in your table? Allow
the user to select the rows he wants to print, then click a single
button outside the table to print all the selected invoices? The
button would submit to a page that loads all the selected invoices,
using window.print in the onload event to bring up the print dialog.

Bob Barrows

Alan wrote:
Thanks for yr help, because my program run in full screen, thus no
icon and buttons, and I expected when the users click print, then a
printer
dialog box appear, they can select which printer they want. So I
still need
the answers. I tried to write in jscript, but don't work, I tried
to post to js.group, noone can answers, I search in Google, over
hundred messages want to do this, but no method, is it possible, or
someone has another
better way to do this ?
"McKirahan" <Ne**@McKirahan.com>
级糶秎ン穝籇:Gt********************@comcast.com. ..
"Alan" <al**@neind.net> wrote in message
news:ON**************@TK2MSFTNGP10.phx.gbl...
> While not rs.eof
> <td><%=rs("InvoiceNo")%></td>
> <td><%=rs("Name")%></td>
> <td><a
> href="InvoicePrint.asp?WInv=<%=rs("InvoiceNo")%>"> </a></td>
> <td>Print this invoice</td> rs.MoveNext
> Wend
>
> Now user needs to click the link to open the invoice, and then
> select File--Print from the menu to print it out, and then return
> back to
> print another. As the table is very long, they need to scroll
> again to find the next one.
>
> I want to make the user more comfortable, that they
> simply click the "Print" button in the end of the row, without
> opening the
> page, print the invoice no they want. Is it possible ?
>

You could just open up the Invoice in a new window:

<a href="InvoicePrint.asp?WInv=<%=rs("InvoiceNo")%>"
target="_blank"></a> Also, you could educate your users to click
the printer icon
(one of the Standard Buttons) rather than clicking File+Print.

If you do achieve silent printing I'd inform the user via an
alert() that an invoive print was performed; otherwise, they may
click repeatedly not knowing what's happening --
(as the printer may be located elsewhere).


--
Microsoft MVP - ASP/ASP.NET
Please reply to the newsgroup. This email account is my spam trap so
I don't check it very often. If you must reply off-line, then remove
the "NO SPAM"


--
Microsoft MVP -- ASP/ASP.NET
Please reply to the newsgroup. The email account listed in my From
header is my spam trap, so I don't check it very often. You will get a
quicker response by posting to the newsgroup.
Jul 22 '05 #6

This discussion thread is closed

Replies have been disabled for this discussion.