![]() |
|
[Delphi] For loop in twebbrowser navigate. - Printable Version +- Hack Forums (https://hackforums.net) +-- Forum: Tech (https://hackforums.net/forumdisplay.php?fid=444) +--- Forum: Coding (https://hackforums.net/forumdisplay.php?fid=151) +---- Forum: Coders Lounge (https://hackforums.net/forumdisplay.php?fid=5) +---- Thread: [Delphi] For loop in twebbrowser navigate. (/showthread.php?tid=4130264) |
For loop in twebbrowser navigate. - zsolt1126 - Mar 23, 2014 Hi all. I wanna make a for lopp for this example. webbrowser1.navigate('javascript: $("[value=1]").click();') from webbrowser1.navigate('javascript: $("[value=100]").click();') to the variable is the value will. i will make the clicking with timer. thanks pls help mee * - SBMK - Mar 23, 2014 Code var* - zsolt1126 - Mar 23, 2014 (Mar 23, 2014 07:38 AM)Fеnix Wrote:I tryed bt not work. i give white background in the webbrowser with [object,object] string. here is my code procedure TForm1.Timer1Timer(Sender: TObject); var value:string; i:integer; begin for i :=805762 to 805764 do begin value := 'javascript:$("[name=' + IntToStr(i) + ']").click();'; webbrowser1.navigate(value); end; end; * - SBMK - Mar 24, 2014 (Mar 23, 2014 10:14 AM)zsolt1126 Wrote: I tryed bt not work. i give white background in the webbrowser with [object,object] try to add a delay after every navigate() like sleep for one second. * - zsolt1126 - Mar 25, 2014 (Mar 24, 2014 09:01 AM)Fеnix Wrote: try to add a delay after every navigate() like sleep for one second. The problem was the IE 11. I changed explorer7 and now work.:) The code was good. thanks :) |