[JRex] Re: simulating a click of a link

Aditya Shah adityashah at fastmail.fm
Fri Oct 14 19:17:46 EDT 2005


Thanks Medappa. That worked. I was able to simulate mouse clicks on
href's, being able to follow javascript links also. Here's the code I
used - 

JRexHTMLAnchorElementImpl htmlLink = 
(JRexHTMLAnchorElementImpl)htmlLinkl

					
On Fri, 14 Oct 2005 06:27:20 +0530, "JRex(J'ed TRex)"
<jrex_moz at yahoo.com> said:
> Try using DOM MouseEvents, see 
> http://www.w3.org/TR/DOM-Level-2-Events/events.html#Events-eventgroupings-mouseevents
> 
> +Medappa
> 
> Aditya Shah wrote:
> > Hi,
> > 
> > I am new to JREX. I am using JREX to fill out forms and follow links
> > programmatically. There are methods available to click buttons
> > (button.click()) and to submit forms(form.submit()). Is there a way to
> > simulate a mouse click on a link, and follow that link to the next page? 
> > For e.g., in case of links of the type <a href="javascript:gotoLink()">,
> > I cannot just do a navigator.loadURI() on the HREF value. Also, when the
> > links are going to be server side redirects, then simply taking the href
> > and doing loadURI won't work. So is there a way in which we can click on
> > a link, like there is a method to click a button, which can take care of
> > the above scenarios?
> > 
> > Any help will be appreciated!
> > 
> > Thanks!
> > 
> > Sincerely,
> > Aditya
> > 
> 
> _______________________________________________
> JRex mailing list
> JRex at mozdev.org
> http://mozdev.org/mailman/listinfo/jrex

-- 
http://www.fastmail.fm - Accessible with your email software
                          or over the web



More information about the JRex mailing list