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

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

print from a winform application

Posted By:      Posted Date: October 21, 2010    Points: 0   Category :Windows Application

hey all

i'm desperatlly trying to create some kind of form that contains data that will be filled from the main form of the application that will be printable. i would also like that the user will not be able to see the form.

any suggestions about how to approach this subject?

many thanks.

View Complete Post

More Related Resource Links

Remotely access winform application through admin panel

I am going to develop following application but not sure how to do this   Application will run different instances for various clients on different servers.     Each instance will run on different criteria stored in database managed by an admin.     Would like to be able to run this from the admin section.     Maybe using a server command line component and pipin the output into a web based admin? -- Whatever you think is best.     This application will run basically 24-7   Any best solution, idea etc

Auto saving the Winform application

hi,   I am developing a huge win form application, which has lot of win forms, user controls and wizards. For user it will take some time to fill-in all the fields and complete the wizard. I wanted to implement auto saving the application for every 3-4 minutes, this should be done in the background without disturbing the user activity (or thread)..   can anyone help me to implement this? Please share your ideas.   thanks

Restart a Wpf Application from a WinForm

I have a problem with a solution that I'm trying to develope. This is my scenario: I have a VB6 application and I would call from this application some WPF windows. I've used the Interop Form Library to define a WinForm like a bridge from VB6 to WPF. The Interop WinForm exposes the methods to start and shutdown the wpf application. To do that, in the WPF Application I've defined an helper like this: Public Class StartApplicationHelper Public Shared Property IsReady As Boolean = False Public Shared Event NotifyEvent As ValueEnterEventHandler Public Shared Sub Start() If System.Windows.Application.Current Is Nothing Then Try Dim myApp As Application = New Application myApp.ShutdownMode = ShutdownMode.OnExplicitShutdown myApp.InitializeComponent() IsReady= True Catch ex As Exception MessageBox.Show(ex.Message) End Try End If End Sub Public Shared Sub Shutdown() If System.Windows.Application.Current IsNot Nothing Then System.Windows.Application.Current.Shutdown() IsReady = False End If End Sub Public Shared Sub DispatchEvent(ByVal eve As String) If IsReady Then EventDispatcherService.DispatchEvent(eve, New EventDispatcherDataChildWin(String.Empty, Nothing, Nothing, False)) End Sub Public Shared Sub DispatchResult(ByVal

WCF Membership Authentication and Winform Client Application Services

I am needing more validation of what I am doing versus solving a problem. I have a winforms application that uses Client Application Services to validate a user against a customer membership provider all over SSL.  This works fine.  My winforms application validates correctly. The winforms application uses WCF to call services that are installed on the same IIS server that is providing the membership services for the Client Application Services.  The WCF services use wsHTTP binding, transport security, username credentials, and validate against the same membership provider as the Client Application Services. It appears that although the service and Client Application Services are at the same URL, they do not share credentials between them.  Ideally, once I log into Client Application Services, any calls to a WCF service at that location would be automatically authenticated.  However, this is not true.  I have to pass the username and password into the credentials for the WCF service.  This works as expected where the username and password are validated prior to allowing a service call.  On subsequent services calls, it does not validate again since it has established the secure channel. So, does this sound like the best approach?  Is there a way to pass credentials from the Client Application Services to WCF automatically?  I

Content cutoff in Print preview screen when a print button is clicked from a WPF application in Dell

Hello, I am facing a problem in printing.. I have a WPf+windows application running on the Dell Mini Net book(10") with screen resolution 1366 x 768. I am trying to the print the page with heading, image & some measurements on a 81/2 x 11. the print preview seem to be ok on the desktop(screen resolution 1440 x 900). but when i run same application in dell mini the layout is cutoff, the text is started from the footer area,  the page is not shown completely.. Can any one help me in this regard??   Thanks for the help in advance Archana

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.

client side Print issue in Asp.net application when we hosted in webserver(Global, shaired space).


I have an asp.net application . I hosted this application in shaired server. When the client is logined this site , they have an option for print the certificate based up on the number of copies.  My questin is right now i generated this one pdf, so pdf it self i can print unlimited copies. So i want to restrict this one by blocking the print dialogbox. I want to print it based up on the number of copies from databsase of a table value.  then how to identify the clint side printer to print this one.

Please give any suitable solution for it to print the number of copies without popup the print dialogshop.


So please give a goodd solution for it to print the certificaate in client side based up on the number of copies from database and should be restrict print dialogbox .


Requirments is

 Any methord print client side print based up on the number of copies from database and restrict print dialogbox . User should not be prin number of copiest apart from the number of copies from database.


Please give me the tips for impliment it. and send me source code for easy understanding


Thank You.........

Specifying Where A Service Reference Points In A WinForm Application


I need the actual service reference to the wcf object to be dynamic.  How can I switch between servers (server1, server2) with the same exact signatures and data contracts?


Right now I have to right click and add service reference.  I want to know how I can change the service reference to point to server 1 or server 2 at runtime

Apply Application.EnableVisualStyles to only One WinForm of the Vb .net 2005 application




We have Windows Application developed in Vb .Net 2005 with customized UI.

Now we have requirement in one of the Winform where we need to use Application.EnableVisualStyles() for displaying an grouped ListView Control.

Is it possible to apply Application.EnableVisualStyles() to only one Winform?

Please guide me



Sudhir C N

How to print a pdf from winform without opening it.


I have pdf file saved on my hard disk. I want to print it without opening it in a single click.

Any suggestions will be highly appreciated.


.NET 3.5(2.0) winform control in MFC 7.1 application


Hi all,

I have a WinForm control in .NET 3.5 (can also be compiled with .NET 2.0), created in VS2008, now I'm tasked to embed this control in a legacy MFC 7.1 app (in VS2003). Requirement is to embed the control, not necessary to merge two projects.

Due to dependency on a licenced library, the MFC app can not be upgraded to new VS version.

I'm new to MFC and only have limited experience programming WinForm app. Is this possible at all? If yes, any sample I can follow?

Thanks in advance!

Best Regards,

WinForm application connectivity


I have programmed a WinForm application (.NET 3.5, C#) which runs on multiple client and connect to MS SQL 2005 server. When client application starts, it loads settings to cache. When some global setting has changed, every application have to reload its own. Settings are stored in SQL.

Could you, please, advice some .NET functionality for that?

Thank you!


execute a winform application within a seq workflow


I have a need to run programmatically, a winform application in the ExecuteCode task in my Sequenctial Workflow.

It's not working. The application doesn't initiate. Moving the same code to a winform application works fine.

Is this possible to work? I thought maybe if I created a new AppDomain in the ExecuteCode it might work. It is required that the GUI on nthe server when running the workflow.. I know it's a bad idea, but I don't have a choice.


It's not a great idea, but it has to be done somehow.



Microsoft's Collaborative Application Markup Language (CAML) Loop

discovered an interesting error recently while working with Microsoft's Collaborative Application Markup Language (CAML) that, surprisingly, had received no ink. Partly what surprises me about this is that the error may require you to rewrite large sections of your code if you haven't previously considered this SharePoint limitation. I'll start with some context, but first of all the error is:

Integrating a Legacy Web Application in SharePoint

This month we will continue with the theme of deploying Microsoft's SharePoint as a company intranet by describing a method for integrating a legacy Web application inside a SharePoint site.

In many companies the intranet site is not just a home page with announcements. It houses Web applications used by many different departments. In last month's article, I built a page to search the employee table in Northwind (the sample database included in Microsoft's SQL Server). This month, I will move the Web pages used to add/remove records from the table into the SharePoint intranet.

MVC architecture in ASP.Net using C# and Microsoft Data Access Application block

The Model-View-Controller (MVC) pattern separates the modeling of the domain, the presentation, and the actions based on user input into three separate classes [Burbeck92]:

Model. The model manages the behavior and data of the application domain, responds to requests for information about its state (usually from the view), and responds to instructions to change state (usually from the controller).

View. The view manages the display of information.

Controller. The controller interprets the mouse and keyboard inputs from the user, informing the model and/or the view to change as appropriate.

High-Performance .NET Application Development & Architecture

It has always been a goal of project architects to plan an effective strategy from the ground up in regards to an new application. All relevant factors are taken into consideration with respect to the application, from its design and layout to a functional website infrastructure. Pre-.NET strategies and design guidelines still effective now were developed with Microsoft's DNA (Distributed interNet Application) platform. This model successfully served the purpose of architecting N(any number of)-Tier (levels) applications. In its basic sense, as in most robust, distributed applications, you'll architect 3 main layers or Tiers: presentation, business rules and data access.
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