快捷方式的函数
use shlobj,comobj,activex;//查DEL6VCL.HLP可以查到olecheck属于comobj
procedure link(const appname,savepath:string);
var
sl:IShellLink;
pf:IPersistFile;
lnkname:widestring;
begin
olecheck(cocreateinstance(CLSID_ShellLink,nil,CLSCTX_INPROC_SERVER,IShellLink,sl));
pf:=sl as IPersistFile;
olecheck(sl.setpath(pchar(appname)));
lnkname:=savepath+´´+changefileext(extractfilename(appname),´.lnk´);
pf.save(pwidechar(lnkname),true);
end;