We use cookies to give you the best experience on our website. If you continue to browse, then you agree to our privacy policy and cookie policy. (Last updated on : Nov 16th 2018).
Unfortunately, activation email could not send to your email. Please try again.
Syncfusion Feedback

slow startup of print preview form

Thread ID:

Created:

Updated:

Platform:

Replies:

53075 Dec 7,2006 06:03 PM UTC Dec 8,2006 01:56 PM UTC WinForms 3
loading
Tags: GridControl
Jonathan Hartley
Asked On December 7, 2006 06:03 PM UTC

Hello there!

I've recently implemented Print and Print Preview functionality for our SyncFusion Grid application.

However, the print preview dialog takes around 10 seconds to appear, on the call to .Show, even with an empty grid.

It's a virtual grid - the final three seconds are spent generating 2300 calls to our OnQueryCellInfo() handler. But what about the seven seconds before that?

Any ideas or clues gratefully received,

Thanks,

Jonathan

Administrator [Syncfusion]
Replied On December 8, 2006 09:30 AM UTC

I added the button handler below to the VirtualGrid sample that we ship with the product. Using both .NET 2.0 and 1.1, the dialog appears essentially instantly, and the preview pages start generating as indicated by the little counter window that appears. Are you doing something differently? Do the sample exhibit the sample behavior on your system?

One possible explanation is that there is some kind of time-out going on as the framework looks for a printer on your system. Does your system have a default printer setup and is it connected? Have you tried your code on other systems that might be using a directly connected printer?


private void button1_Click(object sender, EventArgs e)
{
GridPrintDocument pd = new GridPrintDocument(this.gridControl1);
PrintPreviewDialog dlg = new PrintPreviewDialog();
dlg.Document = pd;
dlg.ShowDialog();
}

Administrator [Syncfusion]
Replied On December 8, 2006 09:30 AM UTC

I added the button handler below to the VirtualGrid sample that we ship with the product. Using both .NET 2.0 and 1.1, the dialog appears essentially instantly, and the preview pages start generating as indicated by the little counter window that appears. Are you doing something differently? Do the sample exhibit the sample behavior on your system?

One possible explanation is that there is some kind of time-out going on as the framework looks for a printer on your system. Does your system have a default printer setup and is it connected? Have you tried your code on other systems that might be using a directly connected printer?


private void button1_Click(object sender, EventArgs e)
{
GridPrintDocument pd = new GridPrintDocument(this.gridControl1);
PrintPreviewDialog dlg = new PrintPreviewDialog();
dlg.Document = pd;
dlg.ShowDialog();
}

Jonathan Hartley
Replied On December 8, 2006 01:56 PM UTC

Thanks for the input, Clay.

The print preview dialog appears instantly, but the major delay is before it starts displaying 'generating page 1' (or whatever). It's only in the latter 3 seconds that it displays the page generation messages, while it starts calling our 'onqueryCellInfo', etc.

Thanks for the things you suggest, I'll try them out and report back.

CONFIRMATION

This post will be permanently deleted. Are you sure you want to continue?

Sorry, An error occured while processing your request. Please try again later.

Warning Icon You are using an outdated version of Internet Explorer that may not display all features of this and other websites. Upgrade to Internet Explorer 8 or newer for a better experience.Close Icon

;