0

Basic addAnnotation example

asked 2012-10-15 17:32:59 +0800

wlainer gravatar image wlainer
36

updated 2012-10-15 17:59:38 +0800

Hi, I´m trying to do a basic example of annotation in javacode, but it´s not working. Can anyone tell me what i did wrong?

in my controller, i have:

		Label l = (Label) getWindowAtual().getFellow("teste");
		Map aa = new HashMap();
		aa.put("value", "teste");
		l.addAnnotation("bind", aa);

and in zul i have

		<row style="border: 0px" height="35px">
			<label id="teste" ></label>
		<row>

if anyone can help

thanks

delete flag offensive retag edit

1 Reply

Sort by » oldest newest

answered 2012-10-23 02:14:43 +0800

iantsai gravatar image iantsai
2755 1

an example :

HashMap<String, String[]> annotAttrs = new HashMap<String, String[]>();
annotAttrs.put("value", new String[]{"a.b.c"});
myLbl.addAnnotation("value", "load", annotAttrs);

Your sample code lake of "value" as the first argument while calling addAnnotation();

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

Follow

RSS

Stats

Asked: 2012-10-15 17:32:59 +0800

Seen: 62 times

Last updated: Oct 23 '12

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