Visual Studio .NET - Printing
Asked By shuwen chew
25-Apr-06 11:29 PM
i'm using the "window.print();" to print the page,by clickin a button. But if printing the current windows it will also print out the button(print) as well..any idea that can print without letting people see the button?
example : click a button from previous page but print another page?
click in page A, but print page B
or any other way?
i'm using asp.net
Asked By Rupali Randhave Kolhe
i m learning asp.net
I m not sure in asp.net
But in vb i done this.
On click of print button,
first i set visible property of print btn false.
then i set print cmd.
again i set visible prop. to true
Hope this hint will help u.
if u got solution plz. write here
try this for
hiding the print button
[CODE]
function doPrint()
{
if (navigator.appName.indexOf("Microsoft") != -1)
{
knop.hide();
window.print();
knop.show();
}
else
{
window.print();
}
}
</Script>
</HEAD>
<BODY>
<Script Language="Javascript">
var htmlButton = new String("<input type=button value='Print' onClick='doPrint()'>");
if (navigator.appName.indexOf("Microsoft") != -1)
{
var knop = new NewDiv(window,"button",htmlButton);
knop.output();
knop.show();
}
else
{
document.write(htmlButton);
}
</script>
<BR>
Demo - Demo - Demo - Demo - Demo - Demo<BR>
Demo - Demo - Demo - Demo - Demo - Demo<BR>
Demo - Demo - Demo - Demo - Demo - Demo<BR>
</BODY>
</HTML>
[/CODE]
Error- newDiv is undefined help!
thanks for the solution, but it has an error "newDiv is undefined"..was wondering how to solve it.. i'm on the line..help..
Check this:
http://www.codeproject.com/useritems/PrintPreview.asp
Visual Studio .net .NET Framework Hi NG, ich habe vor längerer Zeit mit Visual Studio .Net 2003 gearbeitet und überlege momentan auf einen neueren Stand upzudaten. Ein Visual Studio .Net 2008 scheint es nicht zu geben. Habe zumindest mit googeln nichts gefunden. Was
Wise for Visual Studio.NET Wise for Visual Studio.NET By Peter A. Bromberg, Ph.D. To "Print This Page" Link Peter Bromberg Wise for Visual Studio .NET is a total and complete installation development system for creating and editing Windows® Installer
Visual Studio versioning . . . . how to tell? .NET Framework To my knowledge, Visual studio 6 was released in 1998, then Visual Studio .NET 2002 is VS 7, then Visual Studio .NET 2003 is VS 7.1, then Visual
visual studio.net 2003 and Access 2007 database .NET Framework Hi I am currently using Visual Studio.Net 2003 running on Windows Server 2000 operating system. I have used Visual Studio.net 2003 connecting to Access 2002 databases in the pass with great success. Now
Is Visual Studio self-hosting ? .NET Framework Does Microsoft use Visual Studio IDE, Visual Studio Debugger, Visual Studio Linker and Visual Studio compiler for developing Visual Studio ? Or is Visual Studio not