.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 pdf from .fo file without preview

Posted By:      Posted Date: September 23, 2010    Points: 0   Category :WPF


I have a file. xsl and its file. xml.
I need to print the result of merging the two files(.fo file) without the preview to the user and without saving the result (pdf) to disk.
is it possible?


View Complete Post

More Related Resource Links

Printing: Preview and Print from Your Windows Forms App with the .NET Printing Namespace


Printing is an integral part of every complete Windows-based application. Providing robust printing capabilities in these applications has often proved to be a tedious chore. Now, printing from Windows Forms with the .NET Framework means you must adopt a document-centric approach, resulting in cleaner and more manageable code. While the System.Windows.Forms namespace provides seamless integration with all the standard print dialogs (such as Print Preview, Page Setup, and Print), the System.Drawing.Printing namespace offers numerous classes for extensibility and customization. These classes, and how they provide access to printing capabilities, are covered here. Other useful techniques, such as printing in the background to allow the user to continue other tasks, is also explained.

Alex Calvo

MSDN Magazine February 2003

Can't paste text into an Infopath form and see it with print preview

I have a user who says that they can't view any of their text that they cut and paste into the fields of a form when they choose Print Preview, in the forms library.  They're using IE8 to access the SharePoint site. When I access the same form in the same library from any browser from my computer, I can view pasted text in any field when I click Print Preview. Anyone see this before and can help me?? Thanks!    

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

How to display print preview from code ?

Hi i'm working on a winform app which hosted of infopath form. is there any way to display print preview of infopath form from code ? in my form, i've used this code to show print preview of the current infopath form : this.formControl1.XmlForm.Print(true); but i got this exception : Specified cast is not valid. can anybody help me where is my problem and how to work-around this ? thanks in advance http://www.codeproject.com/KB/codegen/DatabaseHelper.aspx

Calendar does not print events, Print preview shows blank calendar


We are running SharePoint 2010 and when I do a print preview of a Calendar web part the preview shows a blank Calendar with no events, when I print there are no events printed either.  This is from a PC running Windows XP SP3 and IE7.  When I preview and print from the same computer using FireFox 3.6.10 the events are visible and print.

Since not all of our users have FireFox I need to find a way to get calendar printing to work from IE7.

Single Click File Upload with Preview and no heartache


Combing the web for a simple file uploader for ASP.NET with a server side save and preview capability didn't reveal anything simple, and I noticed a lot of people were struggling to get something too.

I figured this example out today. It uses existing techniques and is simple. Downside is that you have to use session for the temporary store, and the Ajax AsyncFileUpload usess session too.

Written in VS 2010 - I hope you find it useful. This is the basic working code - that should easily be exandable even for more demanding requirements such as  Repeater controls etc.


<%@ Page Title="Home Page" Language="C#" MasterPageFile="~/Site.master" AutoEventWireup="true"
    CodeBehind="Default.aspx.cs" Inherits="FileUploader._Default" %>

<%@ Register Assembly="AjaxControlToolkit" Namespace="AjaxControlToolkit" TagPrefix="asp" %>
<asp:Content ID="HeaderContent" runat="server" ContentPlaceHolderID="HeadContent">
    <script type="text/javascript">
        function uploadComplete() {
            requestImgUrl("", "");

        function dataFromServer(imgUrl) {
            document.getElementById("Image1").src = imgUrl;

on file upload image preview in asp.net



when  a Image is uploaded immediately the image preview should display in image control or html image in asp.net.

I try but in all browsers its not working.

pls tell me how to do this task and the image preview should display in all browsers.

Many Thanks in Advance.

Print Without Preview(Crystal Reports)


Guys, I have a page where details are been loaded. Then i have a print button. When i press that button it opens another page where crystal reports viewer is available and loads the report and convert it to PDF and displays it.

Now i need to modify it as it should straightly print when i press the print button rather than going and loading a crystal report viewer. 

Any suggestions please? I tried the PrintToPrinter method, but its not working. I dont want the javascript Window.Print. please help me with any other suggestions.

Printing and Print Preview hangs on a large report


Using SQL Server 2008 R2 Cumlative Update #4 (build 10.50.1746)

A report that is 119 pages long hangs after page 113 in both the print preview and printing.

A different report that is 90 pages long hangs on page 60 in both the print preview and printing.

These reports worked fine before applying the cumulative update #4.

Print Preview diaplays balnk for SSRS reports in ASP.NET

We have some Sql Server Reporting Services server reports in ASP.NET pages using report viewer. After page loads when we try to see print preview option in the File menu it displays blank page (does not display any content of report part). Any help is appreciated. 

Print always hangs from VS2008 report Preview window

I am creating a report in VS2008 that displays with no problem in the Preview window, but whenever I click the Print button from the Preview window while in VS2008, the print window (Printing page 1 of ..) appears but never gets past page 1 and never prints.  If I deploy this report to a SQL 2008 Report Server and run it from Report Manager, I can print from there.  Unfortunately, when it hangs in VS2008, the only way I found to fix it is to kill VS2008 from Task Manager.  I have tried printing to 2 different printers, I tried running small one page reports, it does not seem to matter how small or simple the report is.  I have been using VS2008 for reports off and on for about 4 months, and while I think I have printed from here before, I really cannot say 100% that I have been able to print from the Preview window in the past 4 months.  I cannot find a post anywhere about printing from VS2008 creating problems.  Any ideas of where the problem might be will appreciated.

File Splitter in .Net

I love to do utility programs in .Net. And this is one of them. As I was playing with JSplit (a free file splitter program), I wondered if I could do it in .Net. The framework supports file operations like reading files in bytes and creating them. It is indeed easy to do file operations in .Net Basics on File operations

Upload Multiple File using JQuery in asp.net

In this article I have explained how to upload multiple files using file upload control. I have used jQuery plugin for uploading multiple files.

I have also explained how to check for file type, file maximum size limit using jQuery & also using server side validation code.

Creating Excel file from C#

I used below coding for create a excel sheet.I got from on web site.
In below coding there is no problem.Its create the excel file.If i run second time,its ask to overwrite the current excel file.If I said "Yes" then it ok ,but If I select cancel button,its generate the Error message.The exception is

Upload a File to a SharePoint Document Library - Part I

The following helper class demonstrates a few techniques that allow documents to be uploaded to a SharePoint document library programmatically without using the API or a custom web service. You don't need to specify a document library name, and it will create any folders specified in the URL as required. File meta data will be updated if any properties are passed.

SmtpClient and Locked File Attachments

Got a note a couple of days ago from a client using one of my generic routines that wraps SmtpClient. Apparently whenever a file has been attached to a message and emailed with SmtpClient the file remains locked after the message has been sent. Oddly this particular issue hasn't cropped up before for me although these routines are in use in a number of applications I've built.

How to call an .exe file in .net

Sometimes a developer has to call an EXE from another EXE. While calling EXE there can be a requirement to pass parameter.
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