如何利用API函数获得Windows启动方式?
在Form1中加入一个CommandButton、一个Label并加入如下代码:Private Declare Function GetSystemMetrics Lib "user32" (ByVal nIndex As Long) As Long Const SM_CLEANBOOT = 67 Private Sub Command1_Click() Select Case GetSystemMetrics(SM_CLEANBOOT) Case 1 Label1 = "安全模式." Case 2 Label1 = "支持网络的安全模式." Case ElseLabel1 = "Windows运行在普通模式." End Select End Sub
页:
[1]