21-01-24, 05:50 PM
شكرا ستاذي الفاضل كل التقدير و الاحترام
ظهرت معي هذه المشكلة:
Your app has entered a break state, but there is no code to show because all threads were executing external code (typically system or framework code).
System.InvalidOperationException: 'Axis Object - Auto interval does not have proper value.'
ظهرت معي هذه المشكلة:
Your app has entered a break state, but there is no code to show because all threads were executing external code (typically system or framework code).
System.InvalidOperationException: 'Axis Object - Auto interval does not have proper value.'
كود :
vb.net
Module Module_Connection
Public DatabaseName As String = "char.mdb"
Public conn As New OleDb.OleDbConnection("Provider=Microsoft.Jet.OLEDB.4.0;Data Source=" & DatabaseName)
End Module
___________________________________________________________________________________________________________
Imports System.Windows.Forms.DataVisualization.Charting
Public Class Form1
Private Sub Form1_Load(sender As Object, e As EventArgs) Handles MyBase.Load
Try
conn.Open()
Dim table As New DataTable("pro")
Dim rs As New OleDb.OleDbDataAdapter("select * from pro ", conn)
rs.Fill(table)
'rs.Dispose()
DataGridView1.DataSource = table
DataGridView1.Refresh()
rs.Dispose()
conn.Close()
Catch ex As Exception
MessageBox.Show(ex.Message)
End Try
End Sub
Private Sub Button1_Click(sender As Object, e As EventArgs) Handles Button1.Click
Chart1.Series.Clear()
Chart1.Series.Add("ذكر")
Chart1.Series("ذكر").Points.AddY(Val(TextBox1.Text))
Chart1.Series.Add("انثى")
Chart1.Series("انثى").Points.AddY(Val(TextBox2.Text))
Chart1.ChartAreas(0).AxisY.Minimum = 0
Chart1.ChartAreas(0).AxisY.Maximum = Val(TextBox1.Text)
End Sub
End Class