Thanks thats a perfect start to what I wanted.

Regards
David



On 13/01/2006, at 5:36 AM, Alex Johnson wrote:

I recommend having doing something like this:

<tr ><td><webobject name="WOHyperlink1"></webobject>

or

<tr ><td><webobject name="WOHyperlink1"></webobject>

Where WOHyperlink1's action is bound to editLink. If you use the latter, watch out for textnodes (aka white-space). Whichever one you use, you'll probably want to make the onclick a little more robust, but these should point you in the right direction.

The other option, I think, might be to use WOGenericContainer for the  <tr>  tag, binding invokeAction to editLink and onclick to a method that returns  "window.location='" + context().componentActionUrl() + "'", but I have never tried this.

Alex Johnson

|| | ||| || | ||| | | |  || || |||
\\ SITE 9 \\ SITE9.COM \\ 503.248.4440 \\



On Jan 11, 2006, at 5:59 PM, Dave Elsner wrote:

Hi,

Does any one have an easy solution to place a _javascript_ onClick of a table row thats in a WORepeition



the Action i need to call  is:

        public WOComponent editLink()


    {


            editFlag = true;


              myDisplayGroup.selectObject(aItem);


         return this.context().page();


    }



I tried adding: 

public String onClickLocation()


      {


                return "document.location='<WEBOBJECT NAME=WOActionURL1></WEBOBJECT>';";


      }



WOActionURL1: WOActionURL {


action = "">


}




and setting onClick to that but that doesn't replace WOActionURL1 with the real url.


I also tried adding a _javascript_ function using the WOActionURL1 which calls  editLink() okay but it then has no idea of where the current repeition is up to and I get aItem = null;



I have got it to work using a DA  but would like a more light weight solution that can be easily reused.




-------
Dave _______________________________________________
Do not post admin requests to the list. They will be ignored.
Webobjects-dev mailing list      ([email protected])
Help/Unsubscribe/Update your Subscription:

This email sent to [EMAIL PROTECTED]
 _______________________________________________
Do not post admin requests to the list. They will be ignored.
Webobjects-dev mailing list      ([email protected])
Help/Unsubscribe/Update your Subscription:

This email sent to [EMAIL PROTECTED]

 _______________________________________________
Do not post admin requests to the list. They will be ignored.
Webobjects-dev mailing list      ([email protected])
Help/Unsubscribe/Update your Subscription:
http://lists.apple.com/mailman/options/webobjects-dev/archive%40mail-archive.com

This email sent to [email protected]

Reply via email to