From: <pas...@ya...> - 2004-02-25 09:28:17
|
Hi, I load a page which contains 2 frames(one left and one right). An action of first frame updates the page of the second frame. I load correctly the parent html page with 2 frames and collects correctly each frame of pages with the getFrames() method. When I execute an action on the first frame(obj1), the second frame is updated. The problem is to collect the second frame after the update on the second frame. to be more clear : obj0 => parent HtmlPage contains 2 frames obj1 => first frame of obj0 obj1 => second frame of obj0 1: obj0 ==> getFrames ==> (2 obj HtmlPage : obj1 and obj2) 2: check a <SELECT> and execute a JavaScript on obj1 => this action udpates the second page of frame. obj2 is the object before the update. ==> How to get the new obj2 ? How can I collect a new HtmlPage object obj2 which is updated after the action on the obj1 ? Pascal. Yahoo! Mail - Votre e-mail personnel et gratuit qui vous suit partout ! Créez votre adresse sur http://mail.yahoo.fr |
From: Mike B. <mb...@Ga...> - 2004-02-25 12:21:13
|
pascal NICOLAS wrote: > How can I collect a new HtmlPage object obj2 which is > updated after the action on the obj1 ? I don't think I understand the problem. You already have the top level page which contains two frames. You can ask each one of those frames for their content (another Page). What are you trying to do that you are having trouble with? -- Mike Bowler Principal, Gargoyle Software Inc. Voice: (416) 822-0973 | Email : mb...@Ga... Fax : (416) 822-0975 | Website: http://www.GargoyleSoftware.com |
From: <pas...@ya...> - 2004-04-29 17:05:10
|
I come back on this problem. I worked on another thing since 2 month but now, I returns on this. I have a top level page which contains 2 frames. In the first frame, I load a page with 3 radiobox. When I click on one or another radiobox of this page, the page of the second frame is updated. My problem is to collect the updated page of my top level page. In fact, I collect the content of my second frame before update but I don't know how can I collect it after the update(after action on radiobox). With an example code : /**************************************/ //Initialize the url. java.net.URL url = new java.net.URL(args[0]) ; WebClient webClient = new WebClient() ; ScriptEngine se = webClient.getScriptEngine() ; //here, I collect the page which contains my 2 frames. HtmlPage page = (HtmlPage) webClient.getPage(url); try { //collect the first and the second frames. //The first frame is not change the second for moment. //An action on the first updates the second frame. fr1 = getFrameByIndex(page,0,"Frame1(index)"); fr2 = getFrameByIndex(page,1,"Frame2(page before update action)"); //I execute an action to change the contents of the second frame. fr3 = execJS(fr1,se,"Jscript code to update second page of frame","UPDATE") ; ????=> Now, How can we collect again the top level page with the first page and the updated second page ? How can I collect directly the updated second page ? I don't find the solution for moment. /**************************************/ I hope that it's more clear for you. Pascal. --- Mike Bowler <mb...@Ga...> a écrit : > pascal NICOLAS wrote: > > How can I collect a new HtmlPage object obj2 which > is > > updated after the action on the obj1 ? > > I don't think I understand the problem. You already > have the top level > page which contains two frames. You can ask each > one of those frames > for their content (another Page). > > What are you trying to do that you are having > trouble with? > > -- > Mike Bowler > Principal, Gargoyle Software Inc. > Voice: (416) 822-0973 | Email : > mb...@Ga... > Fax : (416) 822-0975 | Website: > http://www.GargoyleSoftware.com > > > ------------------------------------------------------- > SF.Net is sponsored by: Speed Start Your Linux Apps > Now. > Build and deploy apps & Web services for Linux with > a free DVD software kit from IBM. Click Now! > http://ads.osdn.com/?ad_id=1356&alloc_id=3438&op=click > _______________________________________________ > Htmlunit-user mailing list > Htm...@li... > https://lists.sourceforge.net/lists/listinfo/htmlunit-user Yahoo! Mail : votre e-mail personnel et gratuit qui vous suit partout ! Créez votre Yahoo! Mail sur http://fr.benefits.yahoo.com/ Dialoguez en direct avec vos amis grâce à Yahoo! Messenger !Téléchargez Yahoo! Messenger sur http://fr.messenger.yahoo.com |