on 08-28-2007 8:42 PM
I have a model node of the following structure:
(Parent Model Node) Request
(child model node) Response
(child model node) Result
The node Result have attributes like fname, lname, address etc.
I need to test my webdynpro since we dont have any test data yet coming from Web Service. So i want to insert some values into attributes of Result node. How would i do that?
Sample code or any other suggestion will be appreciated.
Thanks
Nahman
Hi Nahman,
IPrivate<viewname>.IResultElement element = wdContext.nodeResult().createResultElement();
element.setfname("XXX");
element.setlname("XXX");
element.setaddress("XXX");
wdContext.nodeResult().addElement(element);
Write this code and you can get a hardcoded value in your result node for the time being.
Warm Regards,
Murtuza
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
To set the data to result node do as follows(assuming its already instantiated):
wdContext.currentResultNode.setFname("XXXX");
wdContext.currentResultNode.setLname("ZZZZ"); .....etc
Hope this helps.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
User | Count |
---|---|
86 | |
10 | |
10 | |
9 | |
7 | |
7 | |
6 | |
5 | |
4 | |
4 |
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.