[quote="marco".correa]We should like that when "report preview" is canceled the user see a message that is not a error.
Actually we are throwing a exception to cancel a report preview.
Code: Select all
StiOptions.Engine.GlobalEvents.PreviewingReportInDesigner += (s, args) =>
{
// disregard the verification below, this is only a sample to illustrate
// the event that we are using and the exception raised.
if (1 == 1)
throw new Exception("Visualização do relatório cancelada.");
};
You still didn't write what behaviour of the Designer are you waiting for. Do you want the Designer does back to the Design tab?
If there are any error no message will be shown and users will see a blank report. You could show message using MessageBox.Show() method.
Thank you.