Code: Select all
StiPrintReport stiPrintReport;
StiReport report;
public async Task PrintReportAsync()
{
report = await GetReportToPrintAsync(); //This methods get the report I want, prepared to be printed
report.Printing += Report_Printing;
report.Printed += Report_Printed;
stiPrintReport = new StiPrintReport(report);
stiPrintReport.RegisterForPrinting();
await stiPrintReport.PrintAsync();
}
private void Report_Printing(object sender, EventArgs e)
{
throw new NotImplementedException();
}
private void Report_Printed(object sender, EventArgs e)
{
throw new NotImplementedException();
}
Thank you.