Skip to Content
0
Former Member
Jan 07, 2008 at 09:18 AM

ContextException: Unknown child node 0

29 Views

Hi all,

Im creating tabstrip and table dynamically. I created one value attribute(integer type) for inputfield.I will enter number of columns in input field.I binded this attribute to inputfield.

While deploying getting this exception :

com.sap.tc.webdynpro.progmodel.context.ContextException: DataNodeInfo(DynamicTabstripView): unknown child node 0

I wrote this code

IWDTabStrip tabstrip = (IWDTabStrip)view1.createElement(IWDTabStrip.class,"TabStrip");

IWDTab tab = (IWDTab) view1 .createElement(IWDTab.class, "tab");

IWDCaption headerCaption = (IWDCaption)view1.createElement(IWDCaption.class, "HeaderCaption");

headerCaption.setText("Edit");

tab.setHeader(headerCaption);

tab.setVisible(true);

tabstrip.addTab(tab);

IWDTransparentContainer root = (IWDTransparentContainer)view.getRootElement();

IWDTable table = (IWDTable)view1.createElement(IWDTable.class,"TD");

table.bindDataSource(nodeInfo);

table.setVisible(WDVisibility.VISIBLE);

root.addChild(table);

tab.setContent(root);

root.addChild(tabstrip);

IWDLabel label = (IWDLabel) view1.createElement(IWDLabel.class, "lbl");

label.setText("Enter name");

root.addChild(label);

IWDInputField input = (IWDInputField)view1.createElement(IWDInputField.class, "input" );

input.bindValue("" + wdContext.currentContextElement().getInputattr());

input.setEnabled(true);

input.setLength(20);

root.addChild(input);

can anyone give the answer.

Regards

Shirisha