H hendriclee Unregistered / Unconfirmed GUEST, unregistred user! 2009-05-15 #2 我也想知道。www.hellocpp.net中国人自己的codeproject资料库
5 550181923 Unregistered / Unconfirmed GUEST, unregistred user! 2009-05-28 #3 问题小弟已经解决,需要的朋友发EMAIL给我,呵呵malijiu9@126.com或者QQ联系 550181923 需要认证,请在认证里面输入 DELPHI 说着大富翁就可以了
5 550181923 Unregistered / Unconfirmed GUEST, unregistred user! 2009-05-29 #5 呵呵最近忙,忘了,这就贴出来,给大家参考一下啊procedure TForm1.Button2Click(Sender: TObject);var ipentryinfointernetcacheentryinfo; hcachedir:longword; dwlasterror:longword; dwentrysize:longword; cachefile:string; n:integer; neir:string;begin label2.Caption:=''; n:=0; dwentrysize:=0; cachefile:=''; memo1.Clear; memo2.Clear; filelistbox1.Clear; neir:=''; findfirsturlcacheentry(nil,tinternetcacheentryinfo(nil^),dwentrysize); getmem(ipentryinfo,dwentrysize); hcachedir:=findfirsturlcacheentry(nil,ipentryinfo^,dwentrysize) ; if(hcachedir<>0) then begin cachefile:= string(ipentryinfo.lpszLocalFileName); if cachefile<>'' then begin FileListBox1.AddItem(cachefile,filelistbox1); n:=n+1; end; end; freemem(ipentryinfo); repeat dwentrysize:=0; findnexturlcacheentry(hcachedir,tinternetcacheentryinfo(nil^),dwentrysize); dwlasterror:=getlasterror(); if(getlasterror=error_insufficient_buffer) then begin getmem(ipentryinfo,dwentrysize); if(findnexturlcacheentry(hcachedir,ipentryinfo^,dwentrysize)) then begin cachefile:= string(ipentryinfo.lpszLocalFileName); if cachefile<>'' then begin FileListBox1.AddItem(cachefile,filelistbox1); n:=n+1; end; end; freemem(ipentryinfo); end; until(dwlasterror=error_no_more_items); label1.Caption:=inttostr; showmessage('搜索完毕!') ;end;还希望大家多多指教啊!
呵呵最近忙,忘了,这就贴出来,给大家参考一下啊procedure TForm1.Button2Click(Sender: TObject);var ipentryinfointernetcacheentryinfo; hcachedir:longword; dwlasterror:longword; dwentrysize:longword; cachefile:string; n:integer; neir:string;begin label2.Caption:=''; n:=0; dwentrysize:=0; cachefile:=''; memo1.Clear; memo2.Clear; filelistbox1.Clear; neir:=''; findfirsturlcacheentry(nil,tinternetcacheentryinfo(nil^),dwentrysize); getmem(ipentryinfo,dwentrysize); hcachedir:=findfirsturlcacheentry(nil,ipentryinfo^,dwentrysize) ; if(hcachedir<>0) then begin cachefile:= string(ipentryinfo.lpszLocalFileName); if cachefile<>'' then begin FileListBox1.AddItem(cachefile,filelistbox1); n:=n+1; end; end; freemem(ipentryinfo); repeat dwentrysize:=0; findnexturlcacheentry(hcachedir,tinternetcacheentryinfo(nil^),dwentrysize); dwlasterror:=getlasterror(); if(getlasterror=error_insufficient_buffer) then begin getmem(ipentryinfo,dwentrysize); if(findnexturlcacheentry(hcachedir,ipentryinfo^,dwentrysize)) then begin cachefile:= string(ipentryinfo.lpszLocalFileName); if cachefile<>'' then begin FileListBox1.AddItem(cachefile,filelistbox1); n:=n+1; end; end; freemem(ipentryinfo); end; until(dwlasterror=error_no_more_items); label1.Caption:=inttostr; showmessage('搜索完毕!') ;end;还希望大家多多指教啊!