Skip to Content
0
Feb 08, 2005 at 02:09 AM

Adding data to node with cardinality 0..n

19 Views

Hi All,

I am working on an example that requires data to be populated to the controller context node(cardinality 0..n) with information. This controller context is used in multiple views. I collect some data in one view and some data in another view. This context node is has the following structure

|-Context

|-ToModel

|-BusinessPartner (cardinality 0..n - structure ZBUPA)

- BusinessPartnerRole

- BusinessPartnerNo

I am expecting the following result in the node:

BusinessPartnerRole BusinessPartnerNo

1 -


115

2 -


115

3 -


115

I tried using the following piece of code. It didn't work

ZBUPA partner = new ZBUPA();

partner.BusinessPartnerRole("1");

partner.setBusinessPartner("115");

IPrivatePartnerInformation.IBusinessPartnerElement newPartnerNodeElement;

newPartnerNodeElement = wdContext.createIBusinessPartnerElement(partner);

wdContext.nodeToModel().nodeIBusinessPartner().addElement(newPartnerNodeElement);

Any guidance will be greatly appreciated.

Thanks and regards,

Hemanth