标签:
form1.StringGrid1.Options:=form1.StringGrid1.Options + [goRowSelect];
form1.StringGrid1.Options:=form1.StringGrid1.Options - [goRangeSelect];
form1.StringGrid1.Options:=form1.StringGrid1.Options + [goColSizing];
fn:=ExtractFilePath(Application.EXEName) + ‘CQS.MDB‘;
if InternetCheckConnection(‘http://www.baidu.com/‘,1,0) or InternetCheckConnection(‘http://www.sohu.com/‘,1,0) then
begin
url:=‘http://www.3322.org/dyndns/getip‘;
s_USERIP:=form1.IdHTTP1 .Get(URL);
form1.image8.Visible :=false ;
//下面有联网的话才去访问互联网上标签
s:=‘‘;
//s:=‘not expired‘; exit; //鉴于美亚的情况,测试版没有连网验证也可以使用
try
s:=form1.IdHTTP1.Get(‘http://BKYSP.COM/judge_ex.txt‘);
except
try
s:=form1.IdHTTP1.Get(‘http://BKYSP.COM/judge_ex.txt‘);
except ......
if messagebox(self.Handle,‘确定要退出查缉平台吗?‘,‘暴恐音视频快速查缉平台‘,MB_OKCANCEL)=mrOk then
Application.Terminate;
if messagebox(self.Handle, ‘确认要增加该文件吗?‘, ‘请确认修改数据库‘ , MB_OKCANCEL+MB_ICONINFORMATION)=IDOK then
appMD5(s_memo,s_md5,s_size,s_laiyuan)
MessageDlg(‘该文件已经被收录过了!‘,mtError,[mbOK],0);
try
//上传格式,memo和laiyuan因为是人工输入的,都要BASE64编码
return:=IdHTTP1.Get(‘http://BKYSP.COM/UploadMMS.php?key=----------------‘);
return:=return+IdHTTP1.Get(‘http://BKYSP.COM/UploadMMS.php?key=‘+new_mms);
return:=return+IdHTTP1.Get(‘http://BKYSP.COM/UploadMMS.php?key=‘+EncodeString(new_memo));
return:=return+IdHTTP1.Get(‘http://BKYSP.COM/UploadMMS.php?key=‘+EncodeString(new_fromip));
return:=return+IdHTTP1.Get(‘http://BKYSP.COM/UploadMMS.php?key=‘+EncodeString(new_laiyuan));
return:=return+IdHTTP1.Get(‘http://BKYSP.COM/UploadMMS.php?key=----------------‘);
finally
end;
return := StringReplace(return, #$D#$A, ‘‘, [rfReplaceAll]); //去掉所有的换行,这个函数太重要了!
//showmessage(return);
if return=‘okokokokokok‘ then begin
//showmessage(‘ok‘);
//下面要删除该条记录了
form1.ADODataSet1.Delete;
end;
function DownloadFile(Source, Dest: string): Boolean;
begin
try
Result := UrlDownloadToFile(nil, PChar(source), PChar(Dest), 0, nil) = 0;
except
Result := False;
end;
end;
dest:=ExtractFilePath(Application.EXEName)+‘新版暴恐音视频快速查缉平台.rar‘;
if Downloadfile(‘http://BKYSP.COM/新版暴恐音视频快速查缉平台.rar‘,dest) then
showmessage(‘新版本程序下载成功!文件名:新版暴恐音视频快速查缉平台.rar。请解压后覆盖原版本运行即可。‘)
else
showmessage(‘下载新版本程序失败。‘);
end;
{reg := TRegistry.Create;
reg.rootkey:=HKEY_LOCAL_MACHINE;
if not reg.KeyExists(‘HARDWARE\AQingSao‘) then
begin
if MessageDlg(‘错误!0X423879889623424‘,mtError,[mbOK],0)=mrok then
exit;
end;}
标签:
原文地址:http://www.cnblogs.com/themore/p/4717678.html