' - - - - - - - - - - - - -
' - - - - - - - - - - - - -
' Object Oriented Programming 2008, Class 01, Serving TSINT_2010級_夜四技_忠班
' - - - - - - - - - - - - -
' - - - - - - - - - - - - -
' Code Name of this module:
' OOP2008C01.frmMainUI
'
' - - - - - - - - - - - - -
' - - - - - -
' OOP2008C01.frmMainUI [2008-03-04-PM-09-40-24]
' Version: 1.00.02
' Last Updated: (2008 03 04 PM 09 39 53)
' - - - - - -
' OOP2008C01.frmMainUI [2008-03-04-PM-09-37-16]
' Version: 1.00.01
' Last Updated: (2008 03 04 PM 09 30 22)
' - - - - - - - - - - - - -
' - - - - - - - - - - - - -
Public Class frmMainUI
Inherits System.Windows.Forms.Form
' - - - - - - - - - - - - -
' - - - - - - - - - - - - -
' Begin_[2008_03_04_PM_09_11_00]
' Comments by WeiJin Tang (湯偉晉) :
' We should declare it at the module level, i.e. class level.
'
Private m_WeiJin As WjClickFun
'
' End_[2008_03_04_PM_09_11_00]
#Region " Windows Form 設計工具產生的程式碼 "
Public Sub New()
MyBase.New()
'此為 Windows Form 設計工具所需的呼叫。
InitializeComponent()
'在 InitializeComponent() 呼叫之後加入所有的初始設定
End Sub
'Form 覆寫 Dispose 以清除元件清單。
Protected Overloads Overrides Sub Dispose(ByVal disposing As Boolean)
If disposing Then
If Not (components Is Nothing) Then
components.Dispose()
End If
End If
MyBase.Dispose(disposing)
End Sub
'為 Windows Form 設計工具的必要項
Private components As System.ComponentModel.IContainer
'注意: 以下為 Windows Form 設計工具所需的程序
'您可以使用 Windows Form 設計工具進行修改。
'請勿使用程式碼編輯器來修改這些程序。
Friend WithEvents btnTestWJClickFun As System.Windows.Forms.Button
<System.Diagnostics.DebuggerStepThrough()> Private Sub InitializeComponent()
Me.btnTestWJClickFun = New System.Windows.Forms.Button
Me.SuspendLayout()
'
'btnTestWJClickFun
'
Me.btnTestWJClickFun.Location = New System.Drawing.Point(200, 56)
Me.btnTestWJClickFun.Name = "btnTestWJClickFun"
Me.btnTestWJClickFun.Size = New System.Drawing.Size(144, 72)
Me.btnTestWJClickFun.TabIndex = 0
Me.btnTestWJClickFun.Text = "Test WJClickFun"
'
'frmMainUI
'
Me.AutoScaleBaseSize = New System.Drawing.Size(5, 15)
Me.ClientSize = New System.Drawing.Size(424, 389)
Me.Controls.Add(Me.btnTestWJClickFun)
Me.Name = "frmMainUI"
Me.Text = "Main UI for OOP2008C01"
Me.ResumeLayout(False)
End Sub
#End Region
' - - - - - - - - - - - - -
' - - - - - - - - - - - - -
Private Sub Button1_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles btnTestWJClickFun.Click
' Begin_[2008_03_04_PM_09_09_52]
' Comments by WeiJin Tang (湯偉晉) :
' We shouldn't declare ...
'
' We shouldn't declare the variable at the procedure level; instead we should
' declare it at the module level, i.e. class level.
'
'Dim O As WjClickFun
'O = New WjClickFun(5)
'
' End_[2008_03_04_PM_09_09_52]
Me.m_WeiJin.ClickForFun()
End Sub ' Button1_Click
' - - - - - - - - - - - - -
' - - - - - - - - - - - - -
Private Sub Form1_Load(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles MyBase.Load
' Instantiate this module level object in the Form.Load event
Me.m_WeiJin = New WjClickFun(3)
End Sub
' - - - - - - - - - - - - -
' - - - - - - - - - - - - -
End Class