Re: Stale Link Issue

2006-11-12 Thread Peter Stavrinides

Hi David,
A Stale Link Exception usually occurs when data changes between the 
rendering phase and form submission. In other words if any components in 
the page are modified dynamically for instance you might encounter this 
when you submit because the rewind has no recollection of those 
components. (References to the components are stored in a hidden field, 
so when the page submits these are checked, if there are more or less 
fields then the stale link exception is thrown). You should take a look 
at the hints section of the documentation of the For component: 
http://tapestry.apache.org/tapestry4.1/components/general/for.html


Back to your question, it is possible to have multiple textfields, but 
because you are generating them on the fly the stale link exception 
occurs... a quick fix could be to set the parameter volitile="true", 
which prevents the component reference in a hidden field, but you need 
to be carefull using this because form structure will be different for 
render and rewind.


Lastly, also be aware of the data types you use, if you are binding 
objects directly to the component then use a converter 
(IPrimaryKeyConverter 
). 



good luck,
Peter

david joffrin wrote:

Hi,

I have defined something like:
source="ognl:accountFieldDefinitionsList" 
value="ognl:accountFieldDefinition" index="ognl:index" element="tr">


border="0" src="images/spacer.gif" width="1" height="3"/>
src="images/spacer.gif" width="1" height="3"/>


color="#FF"> 


value="ognl:accountFieldDefinition.fieldName"/>:



value="ognl:fieldValue" size="20" maxlength="8"/>



border="0" src="images/spacer.gif" width="1" height="3"/>


value="Cancel" type="button" listener="ognl:listeners.onCancel" 
class="buttons"/>
value="Confirm" type="button" listener="ognl:listeners.onConfirm" 
class="buttons"/>



I am trying to implement a list of TextField.

When I press the Submit button, I have the Stale Link error page coming!

Any idea why it is not possible to have multiple TextField in a page?

Thanks.
DvJ

_
Windows Live^(TM) Messenger has arrived. Click here to download it for 
free! http://imagine-msn.com/messenger/launch80/?locale=en-gb



-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



--
Peter Stavrinides
Albourne Partners (Cyprus) Ltd
Tel: +357 22 750652

If you are not an intended recipient of this e-mail, please notify the sender, delete it and do not read, act upon, print, disclose, copy, retain or redistribute it. Please visit http://www.albourne.com/email.html for important additional terms relating to this e-mail. 



Stale Link Issue

2006-11-10 Thread david joffrin

Hi,

I have defined something like:
	value="ognl:accountFieldDefinition" index="ognl:index" element="tr">


			src="images/spacer.gif" width="1" height="3"/>
			width="1" height="3"/>


 

			value="ognl:accountFieldDefinition.fieldName"/>:



			maxlength="8"/>



	src="images/spacer.gif" width="1" height="3"/>


		listener="ognl:listeners.onCancel" class="buttons"/>
		listener="ognl:listeners.onConfirm" class="buttons"/>



I am trying to implement a list of TextField.

When I press the Submit button, I have the Stale Link error page coming!

Any idea why it is not possible to have multiple TextField in a page?

Thanks.
DvJ

_
Windows LiveĀ™ Messenger has arrived. Click here to download it for free! 
http://imagine-msn.com/messenger/launch80/?locale=en-gb



-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]