Nevron Forum
Back
Login
Register
Login
Register
Home
»
Nevron Vision for NET
»
Nevron Chart for .NET
»
Setting the NChartControl.Cursor property appears to have no effect
Setting the NChartControl.Cursor property appears to have no effect
Post Reply
Setting the NChartControl.Cursor property appears to have no effect
View
Flat Ascending
Flat Descending
Threaded
Options
Subscribe to topic
Print This Topic
Goto Topics Forum
Author
Message
Lance Levendowski
Lance Levendowski
posted 9 Years Ago
ANSWER
Topic Details
Group: Forum Members
Posts: 60,
Visits: 157
Setting the NChartControl.Cursor property appears to have no effect when the mouse is moved over the control during runtime.
Run the following sample code to reproduce the issue. Note that the NChartControl should use the Hand cursor, but it always uses the Default cursor.
Public Class CursorForm
Inherits Windows.Forms.Form
Private _ChartControl1 As Nevron.Chart.WinForm.NChartControl
Public Sub New()
MyBase.New()
Me.Size = New Drawing.Size(640, 480)
Me.StartPosition = FormStartPosition.CenterScreen
Dim series As New Nevron.Chart.NBarSeries
series.BarShape = Nevron.Chart.BarShape.Bar
series.AddDataPoint(New Nevron.Chart.NDataPoint(3))
series.AddDataPoint(New Nevron.Chart.NDataPoint(1))
series.AddDataPoint(New Nevron.Chart.NDataPoint(2))
series.AddDataPoint(New Nevron.Chart.NDataPoint(5))
series.AddDataPoint(New Nevron.Chart.NDataPoint(4))
Me._ChartControl1 = New Nevron.Chart.WinForm.NChartControl
Me._ChartControl1.Dock = DockStyle.Fill
Me._ChartControl1.Settings.RenderSurface = Nevron.GraphicsCore.RenderSurface.Window
'
'ISSUE: Setting the NChartControl.Cursor property appears to have no effect when the mouse is moved over the control during runtime.
Me._ChartControl1.Cursor = Cursors.Hand
'
Me.Controls.Add(Me._ChartControl1)
Dim chart As Nevron.Chart.NCartesianChart = DirectCast(Me._ChartControl1.Charts(0), Nevron.Chart.NCartesianChart)
chart.Series.Add(series)
End Sub
End Class
Reply
Like
0
Nevron Support
Nevron Support
posted 9 Years Ago
ANSWER
Post Details
Group: Administrators
Posts: 3.1K,
Visits: 4.2K
Hi Lance,
The Cursor property is not regarded as the control also needs to operate under WPF. The following code shows how to change the default cursor:
INMouseService mouseService = (INMouseService)nChartControl1.View.GetServiceOfType(typeof(INMouseService)); mouseService.DefaultCursor = Cursors.Cross;
Best Regards,
Nevron Support Team
Reply
Like
0
Lance Levendowski
Lance Levendowski
posted 9 Years Ago
ANSWER
Post Details
Group: Forum Members
Posts: 60,
Visits: 157
Works perfect. Thanks!
Reply
Like
0
GO
Merge Selected
Merge into selected topic...
Merge into merge target...
Merge into a specific topic ID...
Open Merge
Post Reply
Similar Topics
Post Quoted Reply
Reading This Topic
Login
Login
Remember Me
Reset Password
Resend Validation Email
Login
Explore
Messages
Mentions
Search