This is the problem: I have a screen and some custom controls defined in xml files. That’s okay. Now I want from java to take one panel of this screen in order to add there one of my custom controls. Is there a way to do that without creating a new control dynamically (the builders)? I mean, can I get or lad the xml custom control and then add it in this panel?
I know how to include and use this custom control within this xml file (gui). What I want to do now is to iclude this custom control dynamically (in java code) in one of the gui elements (for example in a ‘panel2’). Is there a way to call this control (custom_control.xml) dynamically? Or should I create a new one in java (with the builders)?
So you defined a custom control in xml and want to instantiate it in java?
We do that too. Here’s how
You create your own Builder and chain your parameters through to the nifty control you are creating.
You pass the control name, as defined in your custom control, in the super constructor.
Heres an example of one of ours, where you can see how we pass the parameters to the control.