We use cookies to give you the best experience on our website. If you continue to browse, then you agree to our privacy policy and cookie policy. (Last updated on: November 16, 2018).
Unfortunately, activation email could not send to your email. Please try again.
Syncfusion Feedback

Eventing Timing

Thread ID:

Created:

Updated:

Platform:

Replies:

21280 Nov 5,2004 02:29 PM UTC Nov 14,2004 07:13 PM UTC WinForms 2
loading
Tags: Chart
Andrew
Asked On November 5, 2004 02:29 PM UTC

Hello, I''m experiencing issues with the firing of events in the chart control. I have a function on my windows form that creates the desired chart from values returned from a database. This works fine, my problem comes with printing the chart. I have a print routine that calls the function that creates the desired chart. Call InitializeChartData(forum_id, cust_id) A few lines down I make the call to the print function: pd.Print(); The problem I am having is that a red line I paint on the axis is not printing. Here is the function that draws the line: Private Sub chartControl1_ChartAreaPaint(ByVal sender As Object, ByVal e As System.Windows.Forms.PaintEventArgs) Handles ChartCntrlStrScrd.ChartAreaPaint Dim chartAreaRect As Rectangle = Me.ChartCntrlStrScrd.GetChartAreaBounds Dim rangeLength As Double = Me.ChartCntrlStrScrd.PrimaryXAxis.Range.Max - Me.ChartCntrlStrScrd.PrimaryXAxis.Range.Min If (Me.ChartCntrlStrScrd.PrimaryXAxis.Range.Max > 0) And (Me.ChartCntrlStrScrd.PrimaryXAxis.Range.Min < 0) Then Dim xposition As Double = chartAreaRect.Width * Me.ChartCntrlStrScrd.PrimaryXAxis.Range.Max / rangeLength e.Graphics.DrawLine(New Pen(Color.Red), New Point(CInt(xposition), 0), New Point(CInt(xposition), chartAreaRect.Width)) End If End Sub How come this is being called after the print function has completed, hence the red line doesn''t appear on my printed chart? Thanks, Andrew

Davis Jebaraj [Syncfusion]
Replied On November 9, 2004 08:57 PM UTC

Hi Andrew, The ChartAreaPaint event is not taken into account when the document is printed. We will need to modify the behavior to provide a alternative or invoke this event during the printing and saving to a image. I have submitted a fix for this issue and it will be available in a build at the earliest. Thank you for your patience. Regards, Davis

Andrew
Replied On November 14, 2004 07:13 PM UTC

Thank you for the explanation, I look forward to the next available build. Thanks, Andrew >Hi Andrew, > >The ChartAreaPaint event is not taken into account when the document is printed. We will need to modify the behavior to provide a alternative or invoke this event during the printing and saving to a image. > >I have submitted a fix for this issue and it will be available in a build at the earliest. > >Thank you for your patience. > >Regards, > >Davis

CONFIRMATION

This post will be permanently deleted. Are you sure you want to continue?

Sorry, An error occured while processing your request. Please try again later.

Warning Icon You are using an outdated version of Internet Explorer that may not display all features of this and other websites. Upgrade to Internet Explorer 8 or newer for a better experience.Close Icon

;