TWebBrowser 該如何清除歷史資料 |
尚未結案
|
nilson
一般會員 發表:3 回覆:2 積分:1 註冊:2003-05-03 發送簡訊給我 |
|
hagar
版主 發表:143 回覆:4056 積分:4445 註冊:2002-04-14 發送簡訊給我 |
cache file 部份: http://www.delphipages.com/tips/thread.cfm?ID=84
uses wininet procedure TForm1.Button1Click(Sender: TObject); var lpEntryInfo: PInternetCacheEntryInfo; hCacheDir: LongWord (*Handle*); dwEntrySize, dwLastError: LongWord; begin //Get size of first entry in dwEntrySize dwEntrySize := 0; FindFirstUrlCacheEntry(nil, TInternetCacheEntryInfo(nil^), dwEntrySize); //Create structure that can hold entry GetMem(lpEntryInfo, dwEntrySize); //Get first cache entry and handle to retrieve next entry, output url hCacheDir := FindFirstUrlCacheEntry(nil, lpEntryInfo^, dwEntrySize); if hCacheDir <> 0 then Memo1.Lines.Add(string(lpEntryInfo^.lpszSourceUrlName)); //Use this line to Delete {DeleteUrlCacheEntry(lpEntryInfo^.lpszSourceUrlName);} //free structure FreeMem(lpEntryInfo); //retrieve all subsequent entries repeat dwEntrySize := 0; FindNextUrlCacheEntry(hCacheDir, TInternetCacheEntryInfo(nil^), dwEntrySize); dwLastError := GetLastError(); if GetLastError = ERROR_INSUFFICIENT_BUFFER then begin GetMem(lpEntryInfo, dwEntrySize); if FindNextUrlCacheEntry(hCacheDir, lpEntryInfo^, dwEntrySize) then Memo1.Lines.Add(string(lpEntryInfo^.lpszSourceUrlName)); FreeMem(lpEntryInfo); end; until dwLastError = ERROR_NO_MORE_ITEMS; end;其它造訪以下這個站吧, 它專們講 delphi & IE 的: http://www.euromind.com/iedelphi/index.htm --- Everything I say is a lie. 發表人 - hagar 於 2003/11/11 07:21:37 |
Ktop_Robot
站務副站長 發表:0 回覆:3511 積分:0 註冊:2007-04-17 發送簡訊給我 |
本站聲明 |
1. 本論壇為無營利行為之開放平台,所有文章都是由網友自行張貼,如牽涉到法律糾紛一切與本站無關。 2. 假如網友發表之內容涉及侵權,而損及您的利益,請立即通知版主刪除。 3. 請勿批評中華民國元首及政府或批評各政黨,是藍是綠本站無權干涉,但這裡不是政治性論壇! |