以下程式未經驗證: // 檢查 Windows95 是否有SoftICE 執行中 function SoftIce95Running : Boolean; var hFile : THandle; begin Result := False; hFile := CreateFile ('\\.\SICE', GENERIC_READ or GENERIC_WRITE, FILE_SHARE_READ or FILE_SHARE_WRITE, nil, OPEN_EXISTING, FILE_ATTRIBUTE_NORMAL, 0); if hFile <> INVALID_HANDLE_VALUE then begin CloseHandle (hFile); Result := True; end; end; // 檢查 WindowsNT 是否有SoftICE 執行中 function SoftIceNTRunning : Boolean; var hFile : THandle; begin Result := False; hFile := CreateFile ('\\.\NTICE', GENERIC_READ or GENERIC_WRITE, FILE_SHARE_READ or FILE_SHARE_WRITE, nil, OPEN_EXISTING, FILE_ATTRIBUTE_NORMAL, 0); if hFile <> INVALID_HANDLE_VALUE then begin CloseHandle (hFile); Result := True; end; end;