我想在后台运行我的VB6应用程序或对用户不可见。
我们怎样才能实现它?
答案 0 :(得分:4)
只需将其写为无形应用程序,或者将其写入Sub Main()
然后Load
,但不要Show
您的主表单。
Module1.bas
Option Explicit
Private Sub Main()
Load Form1
End Sub
Form1.frm
Option Explicit
Private Sub Form_Load()
Timer1.Interval = 5000
Timer1.Enabled = True
End Sub
Private Sub Timer1_Timer()
If MsgBox("Hello", vbOKCancel) = vbCancel Then Unload Me
End Sub