Hi, I have the same problem. The issue is that DirectLink allows you to create the link in the HTML page with parameters. When you click on that link, the page is NOT submitted, rather control is transferred to whereever the link is pointing to and it only passes the parameters in the link. Those parameters were created when the HTML was generated by Tapestry. Therefore any changes you have made to the data on the screen can NOT be in those links.
With LinkSubmit it is very similar. A LinkSubmit causes the whole form to be submitted with all of your changes packaged up and sent to Tapestry to post into your variables. However, the fact that you clicked on a Link and the parameters from that link are NOT sent along which is why you get "0". What you need is something called a Parameterized Link Submit. The current LinkSubmit does NOT allow you to specify a Parameter. Link Submit Definition of available Parameters: (see http://jakarta.apache.org/tapestry/3.0.3/doc/ComponentReference/LinkSubmit.html) Parameters Name Type Direction Required Default Description disabled boolean in no false Controls whether the link is produced. If disabled, the portion of the template the link surrounds is still rendered, but not the link itself. selected Object out no This parameter is bound to a property that is updated when the submit button is clicked by the user. The property is updated to match the tag parameter. tag Object in no Tag used with the selected parameter to indicate which Submit button on a form was clicked. listener IActionListener in no If specified, the listener is notified. This notification occurs as the component is rewinded, i.e., prior to the Form's listener. In addition, the selected property (if bound) will be updated before the listener is notified. So, there is NO way to specify which link was clicked. Glen posted a modified LinkSubmit that allows you to pass in parameters. I haven't had any luck getting it to work properly. Here is the link http://www.jroller.com/page/gstamp/20050514 Good Luck and if you it working let me know ;-). I think part of my issue with it is that I have conditional elements on my page and it is causing me grief. regards, Mark -----Original Message----- From: Muhariz Jabeer [mailto:[EMAIL PROTECTED] Sent: Wed 8/17/2005 12:46 PM To: Tapestry users Subject: LinkSubmit not passing in arguments hi guys, I have this problem where i have to use LinkSubmit instead of DirectLinks to keep persistence within a set of tabs in an application. The problem i am having is, if i use DirectLink, the parameters arguement can be used to pass information. However, LinkSubmit doesnt allow me to pass parameters to the server. Everytime i try to get the serviceParameters( ) from the listener, i get a "0"? Any ideas how i can make LinkSubmit work for me? Basically i need to pass a String from my Tab Component to the server, I'm using DirectLink now, but i really need it to be a submission to the server when u click any of the links. Thanks a lot, any help would be much appreciated. -- In a long enough timeline, every moment will feel like deja vu. -Muhariz.
