⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 oemdiy.cpp

📁 Windows系统OEM信息设置工具
💻 CPP
字号:
//---------------------------------------------------------------------------

#include <vcl.h>
#pragma hdrstop
//---------------------------------------------------------------------------
USEFORM("Main.cpp", FormMain);
//---------------------------------------------------------------------------
WINAPI WinMain(HINSTANCE, HINSTANCE, LPSTR, int)
{
    try
    {
         HANDLE hMutex=CreateMutex(NULL,true,"OEMDIY_Flag");    //建立互斥信号量
         if(GetLastError()==ERROR_ALREADY_EXISTS)               //此互斥量已经存在
         {
            ShowMessage("Windows系统OEM信息设置已经在运行中!");
            ReleaseMutex(hMutex);    //释放互斥量
            return 0;     //退出
         }
         Application->Initialize();
         Application->Title = "Windows 系统 OEM 信息设置";
         Application->CreateForm(__classid(TFormMain), &FormMain);
         Application->Run();
    }
    catch (Exception &exception)
    {
         Application->ShowException(&exception);
    }
    catch (...)
    {
         try
         {
             throw Exception("");
         }
         catch (Exception &exception)
         {
             Application->ShowException(&exception);
         }
    }
    return 0;
}
//---------------------------------------------------------------------------

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -