Re: Retrieve the old value of a field in the form listener

2006-05-29 Thread Martin
I don't know exactly what you need it for, perhaps something like this could work: instead of , you use public String getValue() { return getYourObject().getValue(); } // Called on form submit public void setValue(String value) { if (!value.equals(getYourObject().getValue))

Re: Retrieve the old value of a field in the form listener

2006-05-29 Thread Stephane Decleire
Oups, sorry, i did not see the component specification ... Stephane Decleire wrote: I've parsed your code Marcus and i don't understand what the "hidden" component is ? Could you briefly explain ? Schulte Marcus wrote: Here you go, it's for Tap4 btw: Usage example: value="ognl:fahrzeug.re

Re: Retrieve the old value of a field in the form listener

2006-05-29 Thread Stephane Decleire
I've parsed your code Marcus and i don't understand what the "hidden" component is ? Could you briefly explain ? Schulte Marcus wrote: Here you go, it's for Tap4 btw: Usage example: value="ognl:fahrzeug.reserviertBis" listener="listener:onReservierung"/> value is the property to wat

RE: Retrieve the old value of a field in the form listener

2006-05-29 Thread Schulte Marcus
t; From: Stephane Decleire [mailto:[EMAIL PROTECTED] > Sent: Monday, May 29, 2006 4:26 PM > To: Tapestry users > Subject: Re: Retrieve the old value of a field in the form listener > > > Yes i could ... > but it looks like an elephant gun just to keep the trac of an > ol

RE: Retrieve the old value of a field in the form listener

2006-05-29 Thread Schulte Marcus
Here you go, it's for Tap4 btw: Usage example: value is the property to watch, listener will be called at the end of the rewind cycle, if the prop did change. ___ file Watch.java /* * Erstellt am 23.05.2005 von schultma * copyright, 2005 BMW (Schweiz) AG * * $

Re: Retrieve the old value of a field in the form listener

2006-05-29 Thread Peter Svensson
Hmm. Maybe I misunderstood you. When you enter a value into a field in the page, tapestry will call to the getter for that variable when the page render, and the setter of the variable (with you entered value) when you submit the form of which the (I assume) TextField is a part, like; .. publ

Re: Retrieve the old value of a field in the form listener

2006-05-29 Thread Stephane Decleire
Yes i could ... but it looks like an elephant gun just to keep the trac of an old value that Tapestry has to know ... but where ? :-\ Peter Svensson wrote: Maybe you could store the old value in a state object ? It's described in chapter four of Enjoying Web Development with tapestry, and as

Re: Retrieve the old value of a field in the form listener

2006-05-29 Thread Peter Svensson
Maybe you could store the old value in a state object ? It's described in chapter four of Enjoying Web Development with tapestry, and as it turns out the first four chapters are freely downloadable from; http://agileskills2.org/EWDT/ Then you can save the latest or last value in that object, wh

Re: Retrieve the old value of a field in the form listener

2006-05-29 Thread Stephane Decleire
tener whenever a value is changed. It uses a hidden field to submit the old value along with the new one. If you're interested I could post the code. -Original Message- From: Stephane Decleire [mailto:[EMAIL PROTECTED] Sent: Monday, May 29, 2006 4:11 PM To: Tapestry users Subject: R

RE: Retrieve the old value of a field in the form listener

2006-05-29 Thread Schulte Marcus
e [mailto:[EMAIL PROTECTED] > Sent: Monday, May 29, 2006 4:11 PM > To: Tapestry users > Subject: Re: Retrieve the old value of a field in the form listener > > > Perhaps i took a wrong approach ... > In fact, i need to apply specific code if a particular field > of my form

Re: Retrieve the old value of a field in the form listener

2006-05-29 Thread Stephane Decleire
Perhaps i took a wrong approach ... In fact, i need to apply specific code if a particular field of my form has been updated and not in the other case. So i need to compare the old to the new value of this field but i can't find a way to get the old value after the form has benn submitted ...

Retrieve the old value of a field in the form listener

2006-05-29 Thread Stephane Decleire
Hi all, I need to get the old value of a form field in the listener of this form but i can't get this value before it's been updated with the data submitted by the client ... Any idea is welcome ! -- Stéphane Decleire 05 56 57 99 20 06 63 78 69 06