Skip to Content
0
Former Member
Mar 31, 2011 at 09:53 PM

Crystal 2008 for Visual Studio 2010 - Refreshing Report

26 Views

Hello,

We are developing a Crystal 2008 Viewer in VS 2010 and it's a WPF project (we're using the WPF viewer).

We developed our own Parameter Form so we do not want to use the default one; however, when refreshing the report we get a dialog that states: Click "Yes" to use the current parameter values. Click "No" to prompt for new parameter values."

We do not want this dialog to appear so we set the Handled property to true in the Viewer's Refresh event:

Private Sub viewer_Refresh(source As Object, e As SAPBusinessObjects.WPF.Viewer.ViewerEventArgs) Handles viewer.Refresh
        ' this makes sure that the default param window does not pop up
        e.Handled = True
End Sub

The dialog still appears. Any ideas on how to hide this Dialog?

Currently, we are using a timer and using the SendKeys event after some milliseconds but this does not always catch the dialog:

  Private Sub Timer1_Tick(sender As System.Object, e As System.EventArgs) Handles Timer1.Tick
        Timer1.Enabled = False
        SendKeys.Send("{Enter}")
    End Sub

Thanks,

Tyler