<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>Question Re: Node Has No Valid Parent Error - Initialization in Technology Q&amp;A</title>
    <link>https://community.sap.com/t5/technology-q-a/node-has-no-valid-parent-error-initialization/qaa-p/5398203#M2014601</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi Yogesh Bhatia,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;First create the element to the Parent node. Add the element to the corresponding node and then create the element to its child.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Suppose if you have a structure like this:&lt;/P&gt;&lt;P&gt;Context (level 0)&lt;/P&gt;&lt;P&gt;    -&amp;gt; A Node (Level 1)&lt;/P&gt;&lt;P&gt;         -&amp;gt; B Node (level 2)&lt;/P&gt;&lt;P&gt;              -&amp;gt; attribute (level3)&lt;/P&gt;&lt;P&gt;         -&amp;gt; C attribute (level2)&lt;/P&gt;&lt;P&gt;    -&amp;gt; D Node (level 1)&lt;/P&gt;&lt;P&gt;         -&amp;gt; E Node (level 2)&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;First create element for "A Node" and add it to wdContext.nodeANode().addElement(xxx). and then create element for B Node etc....&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I am assuming that the singleton property for all your nodes in true. &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thanks &amp;amp; Regards,&lt;/P&gt;&lt;P&gt;Jaya.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Tue, 07 Apr 2009 12:43:38 GMT</pubDate>
    <dc:creator>Former Member</dc:creator>
    <dc:date>2009-04-07T12:43:38Z</dc:date>
    <item>
      <title>Node Has No Valid Parent Error - Initialization</title>
      <link>https://community.sap.com/t5/technology-q-a/node-has-no-valid-parent-error-initialization/qaq-p/5398198</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hello please have a look at my context structure. I need to pass the values to a Web Service. These values will also first appear in disabled input fields on my web dynpro screen. How can i initialize these fields with hard coded values?&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Context -&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Context&lt;/P&gt;&lt;P&gt;           - Buyer Party (Node 0..1)&lt;/P&gt;&lt;P&gt;                -- Internal ID (Node 0..1) &lt;/P&gt;&lt;P&gt;                  -- Internal ID (Attribute String)&lt;/P&gt;&lt;P&gt;           - Item (Node 0..1)&lt;/P&gt;&lt;P&gt;               -- Price Component ( Node 0..1)&lt;/P&gt;&lt;P&gt;                -- Price Speicification Code(Node 0..1)&lt;/P&gt;&lt;P&gt;                 -- Text (Attribute String)&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I just want to initialize the two attributes in above context with initial values (hard Coded) to be sent to a service. How do i write my code in the wdDoInit() method?&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 07 Apr 2009 11:25:17 GMT</pubDate>
      <guid>https://community.sap.com/t5/technology-q-a/node-has-no-valid-parent-error-initialization/qaq-p/5398198</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2009-04-07T11:25:17Z</dc:date>
    </item>
    <item>
      <title>Re: Node Has No Valid Parent Error - Initialization</title>
      <link>https://community.sap.com/t5/technology-q-a/node-has-no-valid-parent-error-initialization/qaa-p/5398199#M2014597</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;How is the "singleton" property set for these nodes?&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Armin&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 07 Apr 2009 11:32:54 GMT</pubDate>
      <guid>https://community.sap.com/t5/technology-q-a/node-has-no-valid-parent-error-initialization/qaa-p/5398199#M2014597</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2009-04-07T11:32:54Z</dc:date>
    </item>
    <item>
      <title>Re: Node Has No Valid Parent Error - Initialization</title>
      <link>https://community.sap.com/t5/technology-q-a/node-has-no-valid-parent-error-initialization/qaa-p/5398200#M2014598</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi Armin,&lt;/P&gt;&lt;P&gt;              I am using Netweaver BPM to develop a process. Therein i can set the cardinality property of the Webdynpro Context nodes using a property window.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thnkls&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 07 Apr 2009 11:35:53 GMT</pubDate>
      <guid>https://community.sap.com/t5/technology-q-a/node-has-no-valid-parent-error-initialization/qaa-p/5398200#M2014598</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2009-04-07T11:35:53Z</dc:date>
    </item>
    <item>
      <title>Re: Node Has No Valid Parent Error - Initialization</title>
      <link>https://community.sap.com/t5/technology-q-a/node-has-no-valid-parent-error-initialization/qaa-p/5398201#M2014599</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi Yogesh Bhatia,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Write the code to load the input fields with hard coded values in your view init() method.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;First create an element for Buyer party node and add it to Buyer Party node as &lt;/P&gt;&lt;P&gt;    IPrivate&amp;lt;view name&amp;gt;.IBuyerPartyNodeElement ele =  wdContext.createBuyerPartyNodeElement();&lt;/P&gt;&lt;P&gt;    wdContext.nodeBuyerPartyNode().addElement(ele);&lt;/P&gt;&lt;P&gt;    ele.setInternalId("internal value");&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Make sure you first create element to parent node and then create elements to child nodes.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thanks &amp;amp; Regards,&lt;/P&gt;&lt;P&gt;Jaya.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 07 Apr 2009 12:26:14 GMT</pubDate>
      <guid>https://community.sap.com/t5/technology-q-a/node-has-no-valid-parent-error-initialization/qaa-p/5398201#M2014599</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2009-04-07T12:26:14Z</dc:date>
    </item>
    <item>
      <title>Re: Node Has No Valid Parent Error - Initialization</title>
      <link>https://community.sap.com/t5/technology-q-a/node-has-no-valid-parent-error-initialization/qaa-p/5398202#M2014600</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi Jaya,&lt;/P&gt;&lt;P&gt;           Thanks for your reply.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I am using exactly the same code as you have mentioned.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;However i have not created an element to a parent node. I have directly written the code you have mentioned.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;So for example, if i have a parent node to the BuyerParty node also, what changes can i bring to my code to remove the error? &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;That is how do i create the element for parent node (Please note thta the parent node is not the root node here. BuyerParty has a parent node also)&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thnks&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 07 Apr 2009 12:30:07 GMT</pubDate>
      <guid>https://community.sap.com/t5/technology-q-a/node-has-no-valid-parent-error-initialization/qaa-p/5398202#M2014600</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2009-04-07T12:30:07Z</dc:date>
    </item>
    <item>
      <title>Re: Node Has No Valid Parent Error - Initialization</title>
      <link>https://community.sap.com/t5/technology-q-a/node-has-no-valid-parent-error-initialization/qaa-p/5398203#M2014601</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi Yogesh Bhatia,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;First create the element to the Parent node. Add the element to the corresponding node and then create the element to its child.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Suppose if you have a structure like this:&lt;/P&gt;&lt;P&gt;Context (level 0)&lt;/P&gt;&lt;P&gt;    -&amp;gt; A Node (Level 1)&lt;/P&gt;&lt;P&gt;         -&amp;gt; B Node (level 2)&lt;/P&gt;&lt;P&gt;              -&amp;gt; attribute (level3)&lt;/P&gt;&lt;P&gt;         -&amp;gt; C attribute (level2)&lt;/P&gt;&lt;P&gt;    -&amp;gt; D Node (level 1)&lt;/P&gt;&lt;P&gt;         -&amp;gt; E Node (level 2)&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;First create element for "A Node" and add it to wdContext.nodeANode().addElement(xxx). and then create element for B Node etc....&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I am assuming that the singleton property for all your nodes in true. &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thanks &amp;amp; Regards,&lt;/P&gt;&lt;P&gt;Jaya.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 07 Apr 2009 12:43:38 GMT</pubDate>
      <guid>https://community.sap.com/t5/technology-q-a/node-has-no-valid-parent-error-initialization/qaa-p/5398203#M2014601</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2009-04-07T12:43:38Z</dc:date>
    </item>
    <item>
      <title>Re: Node Has No Valid Parent Error - Initialization</title>
      <link>https://community.sap.com/t5/technology-q-a/node-has-no-valid-parent-error-initialization/qaa-p/5398204#M2014602</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Great Jaya. Thanks a ton. Let me try out.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;And what will be the case if the singleton propoerty is not there for node.?&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 07 Apr 2009 12:46:42 GMT</pubDate>
      <guid>https://community.sap.com/t5/technology-q-a/node-has-no-valid-parent-error-initialization/qaa-p/5398204#M2014602</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2009-04-07T12:46:42Z</dc:date>
    </item>
    <item>
      <title>Re: Node Has No Valid Parent Error - Initialization</title>
      <link>https://community.sap.com/t5/technology-q-a/node-has-no-valid-parent-error-initialization/qaa-p/5398205#M2014603</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi Yogesh Bhatia,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;If singleton property is false for a node then add the nodeelement to a parent like this.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;wdContext.currentBuyerPartyNodeElement().nodeInternalIdNode().addElement(internalnodelement);&lt;/P&gt;&lt;P&gt;// internalnodelement is the element created for Internal Node&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;(or)&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt; IPrivateTest123View.IBuyerPartyNodeElement ele =  wdContext.createBuyerPartyNodeElement();&lt;/P&gt;&lt;P&gt;  wdContext.nodeBuyerPartyNode().addElement(ele);&lt;/P&gt;&lt;P&gt;  ele.setInternalId("internal value");&lt;/P&gt;&lt;P&gt;IPrivateTest123View.IInternalIdNodeElement internalNodeEle = wdContext.createInternalIdNodeElement();&lt;/P&gt;&lt;P&gt;ele.nodeInternalIdNode().addElement(internalNodeEle);&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thanks &amp;amp; Regards,&lt;/P&gt;&lt;P&gt;Jaya.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 07 Apr 2009 12:53:22 GMT</pubDate>
      <guid>https://community.sap.com/t5/technology-q-a/node-has-no-valid-parent-error-initialization/qaa-p/5398205#M2014603</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2009-04-07T12:53:22Z</dc:date>
    </item>
    <item>
      <title>Re: Node Has No Valid Parent Error - Initialization</title>
      <link>https://community.sap.com/t5/technology-q-a/node-has-no-valid-parent-error-initialization/qaa-p/5398206#M2014604</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Thanks a ton Jaya. My problem is solved.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 07 Apr 2009 13:02:39 GMT</pubDate>
      <guid>https://community.sap.com/t5/technology-q-a/node-has-no-valid-parent-error-initialization/qaa-p/5398206#M2014604</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2009-04-07T13:02:39Z</dc:date>
    </item>
  </channel>
</rss>

