on 08-06-2010 2:33 PM
Hi Gurus
I have a node called node1 and it has only one node which is node2 in node2 i have few attributes L1 and L2
Node1
Node 2 - L1 and L2 (L1 and L2 are attributes)
Node1 : Cardinality 0..n
Selection 0..1
Node2 : Cardinality 0..n
Selection 0..1
Can you please suggest how to set the node2 looping at node1.
Thanks and Regards,
Srikanth
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi Baskaran
Appreciate your quick response. I am new to WDA can i get the declarations of the elements. When I tried to create the node as follows:
DATA lo_nd_nd1 TYPE REF TO if_wd_context_node.
DATA lt_nd1 TYPE wd_this->Elements_nd1.
it throws syntax error as
The type "ELEMENTS_ND1" is unknown.
thanks and regards
Srikanth
Try commenting out all the code and activing the component. The context definition generates the interface dynamically and perhaps the generation is off or hasn't occured yet. Generally if you comment out any of the code using the dynamic portions, and activate (which forces generation) things clear up.
Hi,
I notice there are no attributes (yet) in the parent node ND1, so the framework did not generate a type for ND1 - hence the RTE. The code you have will make sense after you create some attributes in ND1, otherwise you don't need an internal table for ND1; you can create elements but only the subelements will have data in attributes L1 and L2.
Regards,
George
Hi Georg
Thank you. you have a valid information. I have tried creating attributes in parent node ND1 now i do not et error.
But I do not need any attribute in ND1.
something like
1. loop ND1
2. loop ND2
3. set attributes for ND2
Can you suggest me hoe to set the nodes.
Thanks and Regards,
Srikanth
Hi,
WebDynpro is a lot about design and less development (coding).
Why do you need then such a hierarchy? What will ND1 represent?
According to such a hierarchy you can have a collection of ND1 elements and each one in turn could have a colection of ND2 elemnts. Without any attributes in ND1 how do you distinguish them? Usually there is a key stored in an attribute which makes them unique.
Regards,
George
Hi Thomas and George
good question... I am developing an application with Business Graphics - Gantt Chart in that application I have the UI elements like Series in that Points and points has Start Value and end Value. Series may have any number of Points (which is again a table)
For this application I have create nodes like Series (parent node) , Point (Child Node).
Please suggest ow to proceed
Thanks and Regards
Srikanth
Hi Thomas and George
I have found this is possible in Webdynpro Java using the below code. The node as define as it is Series as 0-n cardinality with only one child node Point with 0-n as cardinality.
-
IPublicFcTeamCalendar.ISeriesNode seriesNode = wdContext.nodeSeries();
for (int i = 0; i < rowIds.size(); ++i) {
IPublicFcTeamCalendar.ISeriesElement seriesElement = seriesNode.createSeriesElement();
seriesNode.addElement(seriesElement);
IPublicFcTeamCalendar.IPointNode pointNode = seriesElement.nodePoint();
-
Is this possible in Webdynpro ABAP?
Thanks & Regards,
Srikanth Anthargam
You don't have to structure things this way. I checked and I have a series and points - the series bound to a context node and the points are bound to an attribute in that same node. No reason to have a parent/child context. If the parent doesn't have any attributes I still don't see what value it adds.
I would say it isn't possible to have the same structure in WDA, based upon the syntax error you were getting. Frankly it doesn't make any sense to have this pattern - as the parent node serves no purpose without an attribute. It isn't necessary for the IGS series/point. If you absolutely feel you must have this structure, then just create a 1 character dummy attribute.
User | Count |
---|---|
85 | |
10 | |
10 | |
9 | |
7 | |
6 | |
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.