|
|
怎样知道你的程序是运行在安全模式呢? |
|
|
作者:未知 来源:月光软件站 加入时间:2005-2-28 月光软件站 |
Use Windows API GetSystemMetrics with SM_CLEANBOOT parameter, this specifies how the system was started, in your project´s code use:
program Project1;
uses Forms, Windows, Dialogs, Unit1 in 'Unit1.pas' {Form1};
{$R *.RES}
begin Application.Initialize; Application.CreateForm(TForm1, Form1);
case GetSystemMetrics(SM_CLEANBOOT) of 1: begin ShowMessage('Running in Safe Mode: Fail-Safe Boot'); Application.Terminate; end; 2: begin ShowMessage('Running in Safe Mode: Fail-safe with network boot'); Application.Terminate; end; end;
Application.Run; end.

|
|
相关文章:相关软件: |
|