I'not sure if I really understand your question. Perhaps this helps:
HtmlTab tab = new HtmlTab(); HtmlPanel panel = new HtmlPanel(); panel.setParent(tab); //and so on
And do you know the binding attribute and the use of it?
That part works fine..
I am having trouble putting content in the tab.. For example a simple table with a few columns and text..
Hmm...I'm confused. Was that post from you a "Thanks for help" or a "Thanks but my problem is not solved"???
Let's assume the second case :-) Perhaps I'm totally wrong put I think the key to your problem is to set the parent. What I mean:
1.) Create your table with this Html*-Classes.
2.) Create a panel.
3.) Set the panel as parent of the table.
4.) Create a tab.
5.) Set the tab as parent of the panel.
Or does that not work?
Sorry this might be a dumb question..
But the part i am having trouble with is item 1. :)
I dont know how/having trouble creating Html code via java code.
I think once I know the set of classes i am good..
Here is some code i have tried and is not working I get dup id as an error..
HtmlPanel aPanel = new HtmlPanel();
HtmlPanelGrid grid = new HtmlPanelGrid();
HtmlOutputText html1Text = new HtmlOutputText();
html1Text.setValue("Testing 1 2 3");
HtmlOutputText html2Text = new HtmlOutputText();
html2Text.setValue("Testing 3 4 5 6");
I'm not an expert in writing html pages this way but what is wrong with this code (corresponding to my suggestion above):
//1. HtmlDataTable table = new HtmlDataTable(); //2. HtmlPanel panel = new HtmlPanel(); //3. table.setParent(panel); //4. HtmlTab tab = new HtmlTab(); //5. panel.setParent(tab);
Please notice: Set Parent, not child.
ok i will give that a try.
Thank you for all your help.
Ah, don't mention it. I did not say that works. I only wanna say, I understand the documentation in this way ;-)
Nice to have: The sections with headings "Creating the Component Dynamically Using Java" should not be so...short. Or what do you think?
Exactly.. I think they should come up with some really good sample code.
Setting the parent did not work for me. The page did not display the controls.