Private Sub Form_Load()If App.PrevInstance Then
MsgBox "该程序已经运行!"
End
End IfEnd Sub

解决方案 »

  1.   

    If App.PrevInstance = True Then
            MsgBox "本程序已经运行,不能多次运行!", vbExclamation, "警告"
            End
    End If
      

  2.   

    If App.PrevInstance = True Then
            MsgBox "本程序已经运行!", vbExclamation, "警告"
            End
    End If
      

  3.   

    If App.PrevInstance Then
    MsgBox "该程序已经运行!",32
    End
    End If