This is a migrated thread and some comments may be shown as answers.

DataPager reset hinders printing performance

1 Answer 32 Views
DataPager
This is a migrated thread and some comments may be shown as answers.
Tyrone
Top achievements
Rank 1
Tyrone asked on 21 Jul 2011, 03:23 PM
Hi guys,

The app im working on freezes when I print a gridview that has a datapager on it.The problem comes in when setting the pagesize to 0 
and then when resetting the pagesize back to its the original size once the export has completed [BeginExport + Exported in code]. And Inbetween this I have the CreateDocument. I am using a radDocument. Everything is fine when exporting to pdf but printing large amounts of data doesnt work. I see someone had a similar problem and it was never resolved.

Thanks.

protected override void ExportButtonClicked(object sender, RoutedEventArgs routedEventArgs)
        {
            var document = new RadDocument();
 
            Dispatcher.BeginInvoke(() =>
            {
                if (BeginExport != null)
                    BeginExport();
 
                if (ControlWithGridView != null)
                    document = CreateDocument(ControlWithGridView.GridView);
                else if (GridView != null)
                    document = CreateDocument(GridView);
 
                RadRichTextBox.Document = document;
                 
                if (Exported != null)
                    Exported();
            });
 
 
            RadRichTextBox.Print("Prof1t", PrintMode.Native);
             
            RadRichTextBox.Document.History.Clear();
 
             
        }

1 Answer, 1 is accepted

Sort by
0
Pavel Pavlov
Telerik team
answered on 27 Jul 2011, 09:32 AM
Hello Tyrone,

I am trying to reproduce your setup here but I am missing the part with the DataPager. Can you please either paste me some more code so I can see the whole context or even better  - a small runnable projectthat demonstrates the issue  over which I can try add some workarounds and send the modified version back to you.

Regards,
Pavel Pavlov
the Telerik team

Register for the Q2 2011 What's New Webinar Week. Mark your calendar for the week starting July 18th and book your seat for a walk through of all the exciting stuff we will ship with the new release!

Tags
DataPager
Asked by
Tyrone
Top achievements
Rank 1
Answers by
Pavel Pavlov
Telerik team
Share this question
or