Public Class FormForecast
Private Sub Button1_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button1.Click
Me.Hide()
FormDetilFor.Show()
End Sub
Private Sub Cancel_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Cancel.Click
MessageBox.Show("คุณต้องการออกจากหน้านี้", "ข้อความจากระบบ", MessageBoxButtons.OK, MessageBoxIcon.Information)
Me.Close()
End Sub
Private Sub FormForecast_Load(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles MyBase.Load
'TODO: This line of code loads data into the 'FORECASTDataSet3.Transection' table. You can move, or remove it, as needed.
Me.TransectionTableAdapter1.Fill(Me.FORECASTDataSet3.Transection)
'TODO: This line of code loads data into the 'FORECASTDataSet2.Product' table. You can move, or remove it, as needed.
Me.ProductTableAdapter1.Fill(Me.FORECASTDataSet2.Product)
'TODO: This line of code loads data into the 'FORECASTDataSet2.Transection' table. You can move, or remove it, as needed.
Me.TransectionTableAdapter.Fill(Me.FORECASTDataSet2.Transection)
'TextBox1.Text = ComboBox1.SelectedValue
End Sub
Private Sub FillByToolStripButton_Click(ByVal sender As System.Object, ByVal e As System.EventArgs)
Try
Me.ProductTableAdapter.FillBy(Me.TransectionDataSet.Product)
Catch ex As System.Exception
System.Windows.Forms.MessageBox.Show(ex.Message)
End Try
End Sub
Private Sub FillBy2ToolStripButton_Click(ByVal sender As System.Object, ByVal e As System.EventArgs)
Try
Me.TransectionTableAdapter.FillBy2(Me.FORECASTDataSet2.Transection)
Catch ex As System.Exception
System.Windows.Forms.MessageBox.Show(ex.Message)
End Try
End Sub
Private Sub ProductIDToolStripButton_Click(ByVal sender As System.Object, ByVal e As System.EventArgs)
Try
Me.TransectionTableAdapter.ProductID(Me.FORECASTDataSet2.Transection)
Catch ex As System.Exception
System.Windows.Forms.MessageBox.Show(ex.Message)
End Try
End Sub
Private Sub ComboBox1_SelectedIndexChanged(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles ComboBox1.SelectedIndexChanged
TextBox1.Text = ComboBox1.SelectedValue
End Sub
Private Sub FillBy1ToolStripButton_Click(ByVal sender As System.Object, ByVal e As System.EventArgs)
Try
Me.ProductTableAdapter.FillBy1(Me.TransectionDataSet.Product)
Catch ex As System.Exception
System.Windows.Forms.MessageBox.Show(ex.Message)
End Try
End Sub
Private Sub FillBy2ToolStripButton_Click_1(ByVal sender As System.Object, ByVal e As System.EventArgs)
Try
Me.ProductTableAdapter.FillBy2(Me.TransectionDataSet.Product)
Catch ex As System.Exception
System.Windows.Forms.MessageBox.Show(ex.Message)
End Try
End Sub
Private Sub ComboBox1_SelectedValueChanged(ByVal sender As Object, ByVal e As System.EventArgs) Handles ComboBox1.SelectedValueChanged
End Sub
Private Sub FillBy3ToolStripButton_Click(ByVal sender As System.Object, ByVal e As System.EventArgs)
Try
Me.ProductTableAdapter.FillBy3(Me.TransectionDataSet.Product)
Catch ex As System.Exception
System.Windows.Forms.MessageBox.Show(ex.Message)
End Try
End Sub
Private Sub RadioButton1_CheckedChanged(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles RadioMonth.CheckedChanged
'If RadioMonth = ComboBox2 Then
' RadioMonth.Checked = True
'ElseIf RadioMonth = Then
' RadioButton2.Checked = False
'End If
'RadioMonth = ComboBox2.SelectedValue
End Sub
End Class
Tag : .NET, Ms SQL Server 2008, Win (Windows App), VS 2008 (.NET 3.x)