Want to win a PS4? Go Premium and enter to win our High-Tech Treats giveaway. Enter to Win

x
?
Solved

Does 'reportdocument.printToprinter()' print the document at client side ?

Posted on 2009-05-15
6
Medium Priority
?
1,402 Views
Last Modified: 2012-05-07
Does 'reportdocument.printToprinter()' print the document at client side ?
Can anyone help me in this regrad?
0
Comment
Question by:GouthamAnand
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 2
  • 2
  • 2
6 Comments
 
LVL 101

Expert Comment

by:mlmcc
ID: 24395032
I believe it depends on where the report is run.

If on the client then it should print client side.

mlmcc
0
 
LVL 70

Expert Comment

by:Éric Moreau
ID: 24395218
since this line runs on the server (in the code-behind) it will print on the server. you cannot print it on the client directly. you have to show the report and the user can print it.
0
 

Author Comment

by:GouthamAnand
ID: 24395328
protected void btnPrint_Click(object sender, EventArgs e)
    {
        try
        {
            orptDoc = (ReportDocument)Session["report"];
            if (rbtList.SelectedItem.Value == "All")
            {
                fromPage = 0;
                toPage = 0;
            }
            else
            {
                fromPage = Convert.ToInt32(txtFrom.Text);
                toPage = Convert.ToInt32(txtTo.TabIndex);
            }
            if (txtCopies.Text !=string.Empty)
            {
                nCopies = Convert.ToInt32(txtCopies.Text);
            }
            orptDoc.PrintToPrinter(nCopies,false, fromPage, toPage);
        }

Above is my code.
When I press button on my browser (at client side), does print go from client machine? or Will it go from server where the application is deployed which locted somewher else?
0
VIDEO: THE CONCERTO CLOUD FOR HEALTHCARE

Modern healthcare requires a modern cloud. View this brief video to understand how the Concerto Cloud for Healthcare can help your organization.

 
LVL 101

Accepted Solution

by:
mlmcc earned 1000 total points
ID: 24396069
Is the app running onthe client?  Is it installed on the client?

If it is a web page it is probaby running on the server and therefore will print there.

mlmcc
0
 
LVL 70

Assisted Solution

by:Éric Moreau
Éric Moreau earned 1000 total points
ID: 24396093
clicking the button will do a postback to the server and your code will run on the server. the report will be printed on the server.
0
 

Author Closing Comment

by:GouthamAnand
ID: 31581894
Thank you.
0

Featured Post

How to Use the Help Bell

Need to boost the visibility of your question for solutions? Use the Experts Exchange Help Bell to confirm priority levels and contact subject-matter experts for question attention.  Check out this how-to article for more information.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Sometimes in DotNetNuke module development you want to swap controls within the same module definition.  In doing this DNN (somewhat annoyingly) swaps the Skin and Container definitions to the default admin selections.  To get around this you need t…
In .NET 2.0, Microsoft introduced the Web Site.  This was the default way to create a web Project in Visual Studio 2005.  In Visual Studio 2008, the Web Application has been restored as the default web Project in Visual Studio/.NET 3.x The Web Si…
Video by: ITPro.TV
In this episode Don builds upon the troubleshooting techniques by demonstrating how to properly monitor a vSphere deployment to detect problems before they occur. He begins the show using tools found within the vSphere suite as ends the show demonst…
In this video, Percona Solution Engineer Rick Golba discuss how (and why) you implement high availability in a database environment. To discuss how Percona Consulting can help with your design and architecture needs for your database and infrastr…

610 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question