addBinding problem

asked 2010-12-22 22:38:32 +0800

karry gravatar image karry

Hi All
I try to create a Textbox at window onCreate, and want to bind it.
But there are something wrong against my expect.

I use the zk demo site to describe my problem.
In the data binding sample code, I add the follow code on window and try to run it.

<attribute name="onCreate">
AnnotateDataBinder binder = (AnnotateDataBinder) self.getAttribute("binder", Component.COMPONENT_SCOPE);
Textbox nameTbox = new Textbox();
binder.addBinding(nameTbox, "value", "selected.firstName");

The new nameTbox can display name of first row.
But when I select other row, it's value not change.

If I mark the follow tag in grid as comment, and run it again.

				<textbox value="@{selected.firstName}" />

I get the error message:
Cannot find the specified databind bean expression:selected.firstName

How cat I solve these problems ?
Thanks for your help.

delete flag offensive retag edit

1 Reply

Sort by ยป oldest newest

answered 2010-12-30 02:36:47 +0800

karry gravatar image karry

Can anybody help me please !

link publish delete flag offensive edit
Your reply
Please start posting your answer anonymously - your answer will be saved within the current session and published after you log in or create a new account. Please try to give a substantial answer, for discussions, please use comments and please do remember to vote (after you log in)!

[hide preview]

Question tools




Asked: 2010-12-22 22:38:32 +0800

Seen: 389 times

Last updated: Dec 30 '10

Support Options
  • Email Support
  • Training
  • Consulting
  • Outsourcing
Learn More