[Nifty]How to control geometry with buttons?

Helo! I started work with Nifty GUI but I don’t know how to make interactions with my geometry with buttons.
Using

nifty.fromXml("Interface/screen.xml", "start", startScreen);

we should call method from screen.xml file like this

<interact onClick="PivotRotOb(pivot,name)" />

and describe method PivotRotOb(pivot,name) in MyScreenFile.java for example?

But in xml file there is no Nodes or variables. How to pass variables to the method PivotRotOb(pivot,name) in xml or there is another way? May be I am 2 bad in Java…

The variables in the nifty xml files are passed as strings. You can always set a unique name on the node in question and then just pass the name through the onClick method and find it using the root node. You really just have to get a little creative in order to make it work.