Hi, I need to make a printing progress dialog that will show the printing progress and provide the ability to cancel the printing.
What can I use as events / methods to do this ?
I know your report engine provide a progress bar but i don't know how to interface with it.
Any suggestions ?
Question on printing progress
Question on printing progress
You can use event Rendering of report. For example:
For also you can use property StatusString. This property contains status of report rendering.
To stop report rendering you can use property Stop of report. Assign to this property value true to stop rendering.
Thank you.
Code: Select all
report.Rendering += new EventHandler(OnRendering);
//or if you don't load report from assembly or from source code
report.Compile();
report.CompiledReport.Rendering += new EventHandler(OnRendering);
report.Render(false);
private void OnRendering(object sender, EventArgs e)
{
lbStatus.Text = string.Format("Rendering page {0}", (((StiReport)sender).PageNumber - 1));
}
To stop report rendering you can use property Stop of report. Assign to this property value true to stop rendering.
Thank you.