Mega Code Archive

 
Categories / Delphi / LAN Web TCP
 

How to get all Frame URLs in TWebbrowser

Title: How to get all Frame URLs in TWebbrowser procedure TForm1.Button2Click(Sender: TObject); var i: Integer; begin Listbox1.Clear; //if frames available if Webbrowser1.OleObject.Document.Frames.Length 0 then begin //walk through all frames and get the url //to the Listbox for i := 0 to Webbrowser1.OleObject.Document.Frames.Length - 1 do begin Listbox1.Items.Add(Webbrowser1.OleObject.Document.Frames.item(i).Document.URL); end; end; end;