var
hDesktop: THandle;
begin
if stProgram[tmpint] = 'Dos' then
ShellExecute(0, 'open', 'cmd', nil, nil, SW_SHOWNORMAL);
if stProgram[tmpint] = '我的电脑' then
ShellExecute(0, 'open', 'explorer.exe', '::{20D04FE0-3AEA-1069-A2D8-08002B30309D}', nil, SW_NORMAL);
if stProgram[tmpint] = '资源管理器' then
ShellExecute(0, 'open', 'explorer.exe', nil, nil, sw_normal);
if stProgram[tmpint] = '记事本' then
ShellExecute(0, 'open', 'notepad', nil, nil, sw_normal);
if stProgram[tmpint] = '注册表' then
ShellExecute(0, 'open', 'regedit', nil, nil, sw_normal);
if stProgram[tmpint] = '计算器' then
ShellExecute(0, 'open', 'calc', nil, nil, sw_normal);
if stProgram[tmpint] = '画笔' then
ShellExecute(0, 'open', 'msPaint', nil, nil, sw_normal);
if stProgram[tmpint] = '重启' then ShutDown(4);
if stProgram[tmpint] = '关机' then ShutDown(5);
if stProgram[tmpint] = '注销' then ShutDown(2);
if stProgram[tmpint] = '控制面板' then
ShellExecute(0, 'open', 'rundll32.exe', 'shell32.dll,Control_RunDLL ', nil, sw_normal);
if stProgram[tmpint] = '辅助功能选项' then
ShellExecute(0, 'open', 'rundll32.exe', 'shell32.dll,Control_RunDLL access.cpl', nil, SW_SHOWNORMAL);
if stProgram[tmpint] = '添加和删除程序' then
ShellExecute(0, 'open', 'rundll32.exe', 'shell32.dll,Control_RunDLL appwiz.cpl', nil, SW_SHOWNORMAL);
if stProgram[tmpint] = '显示属性' then
ShellExecute(0, 'open', 'rundll32.exe', 'shell32.dll,Control_RunDLL desk.cpl', nil, SW_SHOWNORMAL);
if stProgram[tmpint] = '区域选项' then
ShellExecute(0, 'open', 'rundll32.exe', 'shell32.dll,Control_RunDLL intl.cpl', nil, SW_SHOWNORMAL);
if stProgram[tmpint] = '游戏控制器' then
ShellExecute(0, 'open', 'rundll32.exe', 'shell32.dll,Control_RunDLL joy.cpl', nil, SW_SHOWNORMAL);
if stProgram[tmpint] = '鼠标属性' then
ShellExecute(0, 'open', 'rundll32.exe', 'shell32.dll,Control_RunDLL main.cpl', nil, SW_SHOWNORMAL);
if stProgram[tmpint] = '声音和多媒体属性' then
ShellExecute(0, 'open', 'rundll32.exe', 'shell32.dll,Control_RunDLL mmsys.cpl', nil, SW_SHOWNORMAL);
if stProgram[tmpint] = '调制解调器' then
ShellExecute(0, 'open', 'rundll32.exe', 'shell32.dll,Control_RunDLL modem.cpl', nil, SW_SHOWNORMAL);
if stProgram[tmpint] = '系统特性' then
ShellExecute(0, 'open', 'rundll32.exe', 'shell32.dll,Control_RunDLL sysdm.cpl', nil, SW_SHOWNORMAL);
if stProgram[tmpint] = '时间日期属性' then
ShellExecute(0, 'open', 'rundll32.exe', 'shell32.dll,Control_RunDLL timedate.cpl', nil, SW_SHOWNORMAL);
if stProgram[tmpint] = '屏幕保护' then
SendMessage(HWND_BROADCAST, WM_SYSCOMMAND, SC_SCREENSAVE, 0);
if stProgram[tmpint] = '隐藏桌面' then
begin
hDesktop := FindWindow('Progman', nil);
ShowWindow(hDesktop, SW_HIDE);
end;
if stProgram[tmpint] = '显示桌面' then
begin
hDesktop := FindWindow('Progman', nil);
ShowWindow(hDesktop, SW_SHOW);
end
else
ShellExecute(0, 'open', pchar(stProgram[tmpint]), nil, nil, sw_normal);