.NET Tutorials, Forums, Interview Questions And Answers
Welcome :Guest
Sign In
Win Surprise Gifts!!!

Top 5 Contributors of the Month
david stephan
Gaurav Pal
Post New Web Links

How to print a landscape by using PrintForm control in C# ?

Posted By:      Posted Date: September 09, 2010    Points: 0   Category :Windows Application
How can I print a Windows form in a landscape format by using "PrintForm" control in C# ? "PrintForm.PrinterSettings.LandscapeAngle" is a returned value. Thanks  

View Complete Post

More Related Resource Links

Printing Landscape Report using the Print Control of the ASP.NET Report Viewer

I am using the ASP.NET Report Viewer 2010 web control in remote processing mode connected to a SQL Server Reporting Services 2008 R2 report server in Native Mode. I am viewing the report in IE8 and the print control within the report viewer is available. According to "Printing Reports from a Browser Using the Print Control" at http://msdn.microsoft.com/en-us/library/ms159237.aspx  "The Print dialog box and the default printer settings for width, height, and page orientation are determined by the report definition." In SQL Server Business Intelligence Development Studio I am using the “Report Properties” window accessed from the “Report” menu to set the Orientation to “Landscape”, the paper size to “Letter”, the Width to “11in”, and the Height to “8.5in” in the report definition. When viewing the report using the ASP.NET Report Viewer 2010 in IE8 and exportint to PDF, the report renders correctly in landscape orientation and the size both on screen and printed is as defined in the report definition. However, if I print it directly from the ASP.NET Report Viewer using the Print Control the print preview shows the report correctly in landscape orientation and page size, but the resulting printout is in portrait orientation and skewed or cropped.  If I go into the properti

Automatically print in a landscape format when report does not fit into a portrait format

Good morning,When I print a report, sometimes this report fits into a portrait format, sometimes, it does not, depending of the size of certain field that can grow, do someone know a way to automatically print into a landscape format if it does not fit into a portrait format?, I join the code of this report, when I print it, I have pages thats contain only a few caracters... I do not find how to attach a file here because if I could, I have printed this report in PDF so you will be able to see my problem.Thanks The code seems to be too long to fit in here, I can email to anyone that need to know more  

Does the ReportViewer control print button work inside of a modal MSIE window?

I am getting the following two error messages when using the new ReportViewer v10 control after pressing the toolbar print button. I am only seeing this error inside of a modal popup window in MSIE. The print button in a normal popup window doesn't have this error. An error occurred trying to get the current window Error: Could not complete the operation due to error 8007f305. If anyone knows of a quick fix, please let me know. Thank you. VS2010, MSIE 8, SQL Server 2008.

Unable to load client print control

Hi friends,I am facing one problem since two days in ssrs 2008, i am not able to solve this problem, can any one help me please..Problem Statement:- I am getting "Unable to load client print control"  error when i am trying to give print option from report server.Looking forward for any one help in this problem.

Activex control to Print a Zebra Tag

Hi All, I'm trying to create an Activex control (similar to the Crystal Activex) to Print tag's from a Client side to a Com Port 1. I created a User control I can pass values to it etc, but It won't Print. Any Ideas? User Control Code:Imports System.Text Namespace Tag Public Interface AxMyControl Property UserText() As String End Interface 'AxMyControl Public Class myControl Inherits System.Windows.Forms.UserControl Implements AxMyControl Private mStr_UserText As String Public Property UserText() As String Implements AxMyControl.UserText Get Return mStr_UserText End Get Set(ByVal Value As String) mStr_UserText = Value TextBox1.Text = mStr_UserText Print() End Set End Property Public Function Print() As Boolean Dim tstr As New StringBuilder ' Printer Code tstr.Insert(0, "^XA") tstr.AppendLine("") tstr.Append("^LH5,30") tstr.AppendLine("") tstr.AppendLine("") tstr.Append("^FO75,110^BY1.5") tstr.AppendLine("") tstr.Append("^B3N,N,75,Y,N") t

Print control works on reporting server, but not in embedded in application

Hi,I am having an issue where if I click on the print icon in the report viewer embedded in an application, I get the error "unable to load client print control".  However, when running through report manager, this is fine.  I am running SQL Server 2005 SP3 and report viewer 9.Any thoughts would be much appreciated.

Unable to load client print control

When you display a SQL Reporting Services report to the screen in the header there is a Printer Icon displayed.  When we click this icon we get an error message "Unable to load client print control ". Does anyone know what we need to load or what we need to do to resolve this so that we can print the report directly to teh printer, rather than having ot prinnt the web page, which also prints all the Web headre information

Report Viewer control: Print crashes if subreport is too long



I have a report and a .NET 3.5 Winforms application which displays the report in local mode, passing the required datasets to the report as it is supposed to do. It takes about 2 seconds before the report is displayed.

However, when I click on Print Layout, the "Loading..." box appears and does not disappear any more. If I want to print the report, a window appears telling me that the first page is being sent to the printer and... that's it, all I can do is kill my application via task manager.

After playing around with various elements in my report, I was able to reproduce this behaviour if one of my subreport returns too many rows (the subreport contains only a list element, listing all records).

I believe it has something to do with the subreport spanning more than one page. I played with the KeepTogether property on various elements, but to no avail. Has anybody experienced something like this before? Is there a workaround?



SQL Server 2008 SP2 Windows 7 UAC Prompt Print Control


We recently installed SQL Reporting Services SP2.  When we run Report Manager (i.e http://myserver/reports) and attempt to print a report using the Print control we get UAC prompts for both Vista and Windows 7.  This may not be relevant but if we click Show Information About this Publishers Certificate under UAC prompt it indicates the certificate expired on Feb 22, 2009.  Were the correct CAB files for installing the print control included in SP2?

Most of our clients are running Windows 7/Internet Explorer 8 and are fully patched.  Logged on users are members of local administrators group and the UAC settings are set to default settings.

If we right click IE 8 icon and then "Run As Administrator" we don't get the prompt.  My question is can the UAC prompt somehow be disabled if IE is started without using the "Run As Adminstrator" option and without turning off UAC?


Unable to load client print control


I have a user that had previously installed the client print control and had been printing reports. He used some kind of PC cleanup tool and got the new Norton Antivirus and now he can no longer print and is getting the "Unable to load client print" control whenever he is clicking on the printer icon. He doesn't see any other messages on the screen saying that an Active X control is trying to be installed but is being blocked. What are the next steps that I should take to help him?


Unable to load client print control


When trying to print a report, I get an error message Unable to load client print control.

I get this error when trying to print on all computers.

Unable to load client print control sql2008 sp2


we hade solved this problem in sp1, and distributed an msi package to all clients.

we just put in sp2 and the problem return. this affect no administrato clients.

is there a fix for sp2?

"Unable to Load Client Print Control" after applying CU8 to 2008 SP1


In our environment, users are unable to Install ActiveX controls themselves. Primarily, this is particularly true in our Citrix environment. Upon applying CU8 to our 2008 SP1 SQL Server that we use to run reports, I'm no longer able to manually register the rsclientprint.dll to register the rll's and ActiveX control for users. Is this a known issue? Is there a new method to acheiving this same task?

Due to the size of our citrix environment, manually installing the activeX control through internet explorer on every one of our Citrix servers is NOT an option.

Any assistance is GREATLY appreciated.

Control to Protect content, Restrict Copy & Print



We are developing a web application, where in, it will have a provision for the user to upload his copyrighted content. It should be viewable to the end-users but, it should not allow the user to copy or print the content. First we preferred PDF, but it is having the provision of saving the file to the local disk of the viewer. The save and print functionality shall not be allowed for the users. We cannot have any control onthe user if he uses print-screen button.

Any suggestions on any tools to achieve our gols are welcome.

Thanks in advance.

Cannot print report Unable to load print control


I am using report viewer in VS2010

Whenever I try to print the report I get following error:

Unable to load print control

Along with the I cannot see Print Command in other browser like Mozilla, chrome etc

Plz Help !!!

Adding Dynamic Rows in ASP.NET GridView Control with TextBoxes and with Delete functionality

In my previous examples, I have demonstrated on how to add dynamic rows in GridView control with TextBoxes and how to save the values into the database. Now, seems that most of the developers are asking if how to add a delete functionality with it. So in this example, I'm going to show on how to delete a certain row in the dynamic GridView with TextBoxes.
ASP.NetWindows Application  .NET Framework  C#  VB.Net  ADO.Net  
Sql Server  SharePoint  Silverlight  Others  All   

Hall of Fame    Twitter   Terms of Service    Privacy Policy    Contact Us    Archives   Tell A Friend