📄 unit2.pas
字号:
unit Unit2;
interface
uses
Windows, Messages,Dialogs,Forms,ShellApi, Graphics, Classes, Controls, ExtCtrls, StdCtrls,Registry;
type
TForm2 = class(TForm)
Image1: TImage;
Button1: TButton;
Image2: TImage;
Label1: TLabel;
Label2: TLabel;
Label3: TLabel;
Label4: TLabel;
procedure Image1Click(Sender: TObject);
procedure Button1Click(Sender: TObject);
private
{ Private declarations }
public
{ Public declarations }
end;
var
Form2: TForm2;
implementation
{$R *.dfm}
procedure TForm2.Image1Click(Sender: TObject);
var
Registro: TRegistry;
begin
Registro:= TRegistry.Create;
Registro.RootKey := HKEY_LOCAL_MACHINE;
if Registro.KeyExists('SOFTWARE\Tencent\QQ') then
begin
ShellExecute(GetDesktopWindow(),
nil,
//pchar('http://wpa.qq.com/msgrd?V=1&Uin=743510&Site=多国语言在线翻译V1.0&Menu=yes'),
pchar('Tencent://Message/?Menu=yes&Uin=743510&websiteName=多国语言在线翻译V1.0'),
nil,
nil,
SW_SHOWNORMAL);
end else
begin
showmessage('您的电脑上没有安装QQ,请先安装QQ!');
exit;
end;
end;
procedure TForm2.Button1Click(Sender: TObject);
begin
Form2.Close;
end;
end.
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -