'定义通知区域小图标
Public Dim nfi As
New System.Windows.Forms.NotifyIcon
'图标双击事件'
Public Sub
ICON_DoubleClick(ByVal sender As System.Object, ByVal e As System.EventArgs)
Forms("打卡提醒").Visible = True
Forms("打卡提醒").BaseForm.WindowState
= 0
BaseMainform.Visible = False '设置主窗体隐藏
End Sub
'定义右键菜单
Public Dim cms As
New System.Windows.Forms.ContextMenuStrip
'菜单按钮点击事件
Public Sub
Menu_Click(ByVal sender As System.Object, ByVal e As System.EventArgs)
If sender.Text = "退出" Then
Syscmd.Project.Exit(False)
End If
End Sub
2)项目事件
AfterOpenProject
AddHandler
nfi.DoubleClick, AddressOf Icon_DoubleClick '为通知区域图标添加双击事件
nfi.Text = "打卡提醒"
'鼠标移上去显示的文本
nfi.Icon = New
Icon(ProjectPath & "\TB0018.ico") '图标地址
nfi.Visible = True
'设置为显示