You have to declare the component first ( within the .jwc, .page or through annotations ). While you're declaring it you can use the property option to have tapestry automatically bind the component to a property for you, or you can call a getComponent( "name" ) (something like that, or getComponents().get( "name" ), something..).

So:

.jwc:

<component id="ShowRecordStatus" type="Insert" property="showRecordStatus">
  <binding name="value" value="literal:Record Status"/>
</component>

.java:

public abstract IComponent getShowRecordStatus();



render:

getShowRecordStatus().renderComponent( writer, cycle );



Andreas Bulling wrote:
On 24. Mär 2006 - 14:07:56, Mike Snare wrote:
| Not sure, but have you tried calling render on the component after you
| get it instead of just adding it?
| | Never tried it, just my first thought.

Well, that's right ;)
But the question before is: How can I get an instance of this
component a tall? Do I have to add a ShowRecordStatus <component>
to the .jwc file of the first component or can the same
be achieved by only using Java?

Thanks for your answer anyway ;)

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


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

Reply via email to