Delphi禁止一个程序多次打开.rar
Delphi禁止一个程序多次打开,也就是同一个程序,只允许运行一次, Result := True; GetWindowText(Wnd,@WndCaption, 254);//获取窗口的Caption if(Pos('MyTest',WndCaption)>=1)then //如果窗口的Caption含某字符串 begin if IsIconic(Wnd) then //如果已被最小化 ShowWindow(Wnd,SW_RESTORE)//则把它恢复 else
下载地址
用户评论