How to edit values in a node of cardinality 0...n at runtime.

Hi experts,
I am trying to reset value of an attribute of a node of cardinality 0...n at runtime. I am getting data in this node from a BAPI. I want to set one column's value to zero on display in the table created from this node. Please suggest what to do.
Thanks & Regards.
Vaibhav Tiwari.

Try something like this:
    DATA lo_nd_sflight TYPE REF TO if_wd_context_node.
    DATA lt_sflight TYPE wd_this->elements_sflight.
    FIELD-SYMBOLS: <fs_sflight> TYPE wd_this->element_sflight.
'*   navigate from <CONTEXT> to <SFLIGHT> via lead selection
    lo_nd_sflight = wd_context->get_child_node( name = wd_this->wdctx_sflight ).
'*   get all declared attributes
    lo_nd_sflight->get_static_attributes_table(
      IMPORTING
        table = lt_sflight ).
    LOOP AT lt_sflight ASSIGNING <fs_sflight>.
'*     Here do something like <fs_sflight>-fldate = syst-datum.     
    ENDLOOP.
    lo_nd_sflight->bind_table( lt_sflight ).

Similar Messages

  • How to set value to Model Node of cardinality 0..N

    hi
    I am looking for a way to set value to a model node of cardinality 0..N
    i imported a WSDL into my applicaion , which has the following Node Structure.
    Context
    --- ModelNode_Request
          ---ModelNode2_Input
          ---ModleNode3_Roles  [ cardinality 0..n singleton 1..1]
               ****Model_Attribute RoleID     <<<<<<<<<<<<
               ****Model_Attribute SysID      <<<<<<<<<<<<
      ---ModelNode_Response
    i tried with the below code  but effort went in vain.
    i tried following ways to set the value but , i get Nullpointer expection error.
         wdContext.nodeRequest__SubmitRequest().nodeRequestDetails().nodeRoles().
              currentRolesElement().setRoleId("BASIC");
         wdContext.nodeRequest__SubmitRequest().nodeRequestDetails().nodeRoles().
              currentRolesElement().setSysId("R3_220");
    i aslo looked into the forum  https://www.sdn.sap.com/irj/scn/thread?messageID=2035342 but couldnt find any solid solution.
    It would be great if some one can throw some snippets on the same.
    Thanks
    Edited by: RR on Dec 22, 2008 5:48 PM

    Hi RR,
    As far as i know u can set model nodes and values nodes are different. whats shown in the link is for values node. u should do differently for model node..
        Since this is a model node...u first need to create an object of the node type. then create an arraylist for that and then add values..
    try this..
    // Create an object for structures in the node to be used
    Yweb_Po_Items objPOItems = null; // where Yweb_Po_Items is the structure of the node...
    // Create an abstractlist for structures in the RFC node to be used, if u are planning to give single or multiple rows (in node/table) as input to the RFC
    AbstractList POObjAbsList = new Yweb_Po_Items.Yweb_Po_Items_List();
    objPOItems = new Yweb_Po_Items();
    //    /set first set of values
    objPOItems.setColumn1(u201Cabcu201D); // here hard codede for example
    objPOItems.setColumn2(u201Cabcfghu201D);
    // add the object to the abstract list
    POObjAbsList.add(objPOItems);
    //    /set second set of values
    objPOItems.setColumn1(u201Cnewabcu201D);
    objPOItems.setColumn2(u201Cnewabcfghu201D);
    // add the object to the abstract list again
    POObjAbsList.add(objPOItems); // now u got 2 records
    // now set the abstractlist to the node in the RFC
    objGoodsReceiptPO.setPo_Items_In(POObjAbsList);
    Hope this information is useful...
    Thanks
    Md. Yusuf

  • How to get Value of tree node without Reload Page

    hi,
    i worked with apex 4.2 and i created Tree and tabular form to retrieve the date according the value of tree select node the code of tree something like this
    select case when connect_by_isleaf = 1 then 0
    when level = 1 then 1
    else -1
    end as status,
    level,
    "ENAME" as title,
    null as icon,
    "EMPNO" as value,
    null as tooltip,
    'f?p=36648:34:5234984107903::::P40_SELECTED_NODE:'||empno as link
    from "DEPT"."EMP"
    start with "MGR" is null
    connect by prior "EMPNO" = "MGR"
    order siblings by "ENAME
    and i put Selected Node Page Item: P40_SELECTED_NODE . the tree worked good and retrieve the data into tabular form according to tree node value
    my Question :
    1- i want to retrieve the data without submit the page where each time i select value from tree make page reload to update the tabular form with new value ,there is any way to pass the value of tree node to P40_SELECTED_NODE item and refresh tabular form without page reload .
    2- i want when selected from tree run page process according to value of tree node i tray to create Dynamic action with *(jquery selector : div.tree li>a)* but the Value of node incorrect.
    Regards
    Ahmed;

    look at this link
    Re: How to get Value of tree node without Reload Page ..!

  • Unable to add value to model node with cardinality 0..n

    Hi All,
       Im working with Webdynpro Java.i have an issue here.i have a input field item named customer and a drop down box item location.when i give customer and location as inputs,a WSDL (named Equipment WSDL) is called.the result is a  drop down list containing equipments id
    i took a custom node location with cardinaliy 0..n.i gave static values as input for location.i need to set the location values to model node location.when i m giving a single value to custom node location,that static value is not accepted by model node location(in WSDL) whose cardinality is 0..n.
    Please suugest a solution for this issue
    With Regards,
    Ushasri.

    HI Ushashri,
    What do you mean by 'static value is not accepted by model node location'
    how you have done the mapping
    send me the hierarchy of rfc and ur value node
    With Regards
    Naidu

  • Hardcode values of the node with cardinality 0..n

    Good day!
    I need to hardcode a list of element to the node with cardinality 0..n.
    Node has two attributes.
    How can I fill the node with a few element in the input mapping? I know I can do it with a single element by separating values by comma. Is it possible to fill the node?

    Hello.
    I've the same problem. Can you say how to set list of values for a structure?
    For example, we've node FIELD containing two attributes:  ID and NAME.
    FIELD is a node with cardinality 0..*. How to set at least two elements to the node?
    Your example works only for simple attributes with cardinality 0..*, but it doesn't work for structures.
    Best Regards,
    Timur Semenchuk.

  • How to retrieve values from Referring Nodes

    Hi
    My sample XML nodes are, assume these to nodes are in a same XML file.
    <DestinationBandDefinitionList>
    <DestinationBandDefinition>
    <DestinationBandName>Group 1</DestinationBandName>
    <DestinationList>
    <Destination>
    <Name>India</Name>
    <DestinationIdentifierList type="prefix">
    <Value>91</Value>
    </DestinationIdentifierList>
    </Destination>
    <Destination>
    <Name>USA</Name>
    <DestinationIdentifierList type="prefix">
    <Value>1</Value>
    </DestinationIdentifierList>
    </Destination>
    </DestinationBandDefinition>
    </DestinationBandDefinitionList>
    <DestinationBandDefinitionList>
    <DestinationBandDefinition>
    <DestinationBandName>Group 2</DestinationBandName>
    <DestinationList>
    <Destination>
    <Name>UAE</Name>
    <DestinationIdentifierList type="prefix">
    <Value>971</Value>
    </DestinationIdentifierList>
    </Destination>
    <Destination>
    <Name>Russia</Name>
    <DestinationIdentifierList type="prefix">
    <Value>7</Value>
    </DestinationIdentifierList>
    </Destination>
    </DestinationBandDefinition>
    </DestinationBandDefinitionList>
    <TariffList>
    <DestinationBand>
    <DestinationBandName>Group 1</DestinationBandName>
    <RatingIntervalName>standard1</RatingIntervalName>
    <Rate taxIncluded="false" type="N">3.50</Rate>
    </RateSpecification>
    <RateSpecification>
    <RatingIntervalName>standard2</RatingIntervalName>
    <Rate taxIncluded="false" type="N">3.50</Rate>
    </RateSpecification>
    </RateSpecificationList>
    </DestinationBand>
    What is the statement to query the Taxincluded value of the Group, where USA belongs.
    My DB is Oracle 10g 2.0.1.0
    Thanks in advance
    Rizly

    SQL> with XML as
      2  (
      3    select XMLTYPE(
      4  '<Root>
      5     <DestinationBandDefinitionList>
      6             <DestinationBandDefinition>
      7                     <DestinationBandName>Group 1</DestinationBandName>
      8                     <DestinationList>
      9                             <Destination>
    10                                     <Name>India</Name>
    11                                     <DestinationIdentifierList type="prefix">
    12                                             <Value>91</Value>
    13                                     </DestinationIdentifierList>
    14                             </Destination>
    15                             <Destination>
    16                                     <Name>USA</Name>
    17                                     <DestinationIdentifierList type="prefix">
    18                                             <Value>1</Value>
    19                                     </DestinationIdentifierList>
    20                             </Destination>
    21                     </DestinationList>
    22             </DestinationBandDefinition>
    23     </DestinationBandDefinitionList>
    24     <DestinationBandDefinitionList>
    25             <DestinationBandDefinition>
    26                     <DestinationBandName>Group 2</DestinationBandName>
    27                     <DestinationList>
    28                             <Destination>
    29                                     <Name>UAE</Name>
    30                                     <DestinationIdentifierList type="prefix">
    31                                             <Value>971</Value>
    32                                     </DestinationIdentifierList>
    33                             </Destination>
    34                             <Destination>
    35                                     <Name>Russia</Name>
    36                                     <DestinationIdentifierList type="prefix">
    37                                             <Value>7</Value>
    38                                     </DestinationIdentifierList>
    39                             </Destination>
    40                     </DestinationList>
    41             </DestinationBandDefinition>
    42     </DestinationBandDefinitionList>
    43     <TariffList>
    44             <DestinationBand>
    45                     <DestinationBandName>Group 1</DestinationBandName>
    46                     <RatingIntervalName>standard1</RatingIntervalName>
    47                     <Rate taxIncluded="false" type="N">3.50</Rate>
    48                     <RateSpecificationList>
    49                             <RateSpecification>
    50                                     <RatingIntervalName>standard2</RatingIntervalName>
    51                                     <Rate taxIncluded="false" type="N">3.50</Rate>
    52                             </RateSpecification>
    53                     </RateSpecificationList>
    54             </DestinationBand>
    55     </TariffList>
    56  </Root>') XMLDOC
    57    from dual
    58  )
    59  select xmlquery
    60         (
    61           '$doc/Root/TariffList/DestinationBand[DestinationBandName/text() = $doc/Root/DestinationBandDefinitionList/De
    BandDefinition[DestinationList/Destination[Name="USA"]]/DestinationBandName/text()]/Rate/@taxIncluded'
    62           passing XMLDOC as "doc" returning content
    63         )
    64    from XML;
    false
    Elapsed: 00:00:00.09
    Execution Plan
    Plan hash value: 2594004460
    | Id  | Operation                            | Name                   | Rows  | Bytes | Cost (%CPU)| Time     |
    |   0 | SELECT STATEMENT                     |                        |     1 |       |     2   (0)| 00:00:01 |
    |   1 |  SORT AGGREGATE                      |                        |     1 |     2 |            |       |
    |*  2 |   FILTER                             |                        |       |       |            |       |
    |   3 |    COLLECTION ITERATOR PICKLER FETCH | XMLSEQUENCEFROMXMLTYPE |       |       |            |       |
    |   4 |    NESTED LOOPS                      |                        |   667K|  2606K|   221K  (1)| 00:44:24 |
    |   5 |     COLLECTION ITERATOR PICKLER FETCH| XQSEQUENCEFROMXMLTYPE  |       |       |            |       |
    |*  6 |     COLLECTION ITERATOR PICKLER FETCH| XQSEQUENCEFROMXMLTYPE  |       |       |            |       |
    |   7 |  FAST DUAL                           |                        |     1 |       |     2   (0)| 00:00:01 |
    Predicate Information (identified by operation id):
       2 - filter( EXISTS (SELECT 0 FROM TABLE() "KOKBF$",TABLE() "KOKBF$" WHERE
                  SYS_XQ_UPKXML2SQL(SYS_XQEXVAL(SYS_XQEXTRACT(VALUE(KOKBF$),'/text()'),1,50),50,1,0)=SYS_XQ_UPKXML2SQL(SY
                  S_XQEXVAL(SYS_XQEXTRACT(VALUE(KOKBF$),'/text()'),1,50),50,1,0)))
       6 - filter(SYS_XQ_UPKXML2SQL(SYS_XQEXVAL(SYS_XQEXTRACT(VALUE(KOKBF$),'/text()'),1,50),50,1,0)=SYS_XQ
                  _UPKXML2SQL(SYS_XQEXVAL(SYS_XQEXTRACT(VALUE(KOKBF$),'/text()'),1,50),50,1,0))
    SQL>
    SQL>
    SQL>
    SQL>
    SQL>
    SQL> set heading on
    SQL> with XML as
      2  (
      3    select XMLTYPE(
      4  '<Root>
      5     <DestinationBandDefinitionList>
      6             <DestinationBandDefinition>
      7                     <DestinationBandName>Group 1</DestinationBandName>
      8                     <DestinationList>
      9                             <Destination>
    10                                     <Name>India</Name>
    11                                     <DestinationIdentifierList type="prefix">
    12                                             <Value>91</Value>
    13                                     </DestinationIdentifierList>
    14                             </Destination>
    15                             <Destination>
    16                                     <Name>USA</Name>
    17                                     <DestinationIdentifierList type="prefix">
    18                                             <Value>1</Value>
    19                                     </DestinationIdentifierList>
    20                             </Destination>
    21                     </DestinationList>
    22             </DestinationBandDefinition>
    23     </DestinationBandDefinitionList>
    24     <DestinationBandDefinitionList>
    25             <DestinationBandDefinition>
    26                     <DestinationBandName>Group 2</DestinationBandName>
    27                     <DestinationList>
    28                             <Destination>
    29                                     <Name>UAE</Name>
    30                                     <DestinationIdentifierList type="prefix">
    31                                             <Value>971</Value>
    32                                     </DestinationIdentifierList>
    33                             </Destination>
    34                             <Destination>
    35                                     <Name>Russia</Name>
    36                                     <DestinationIdentifierList type="prefix">
    37                                             <Value>7</Value>
    38                                     </DestinationIdentifierList>
    39                             </Destination>
    40                     </DestinationList>
    41             </DestinationBandDefinition>
    42     </DestinationBandDefinitionList>
    43     <TariffList>
    44             <DestinationBand>
    45                     <DestinationBandName>Group 1</DestinationBandName>
    46                     <RatingIntervalName>standard1</RatingIntervalName>
    47                     <Rate taxIncluded="false" type="N">3.50</Rate>
    48                     <RateSpecificationList>
    49                             <RateSpecification>
    50                                     <RatingIntervalName>standard2</RatingIntervalName>
    51                                     <Rate taxIncluded="false" type="N">3.50</Rate>
    52                             </RateSpecification>
    53                     </RateSpecificationList>
    54             </DestinationBand>
    55     </TariffList>
    56  </Root>') XMLDOC
    57    from dual
    58  )
    59  select xmlquery
    60         (
    61           '$doc/Root/TariffList/DestinationBand[DestinationBandName/text() = $doc/Root/DestinationBandDefinitionList/De
    BandDefinition[DestinationList/Destination[Name="USA"]]/DestinationBandName/text()]/Rate/@taxIncluded'
    62           passing XMLDOC as "doc" returning content
    63         ) RESULT
    64    from XML;
    false
    Elapsed: 00:00:00.10
    Execution Plan
    Plan hash value: 2594004460
    | Id  | Operation                            | Name                   | Rows  | Bytes | Cost (%CPU)| Time     |
    |   0 | SELECT STATEMENT                     |                        |     1 |       |     2   (0)| 00:00:01 |
    |   1 |  SORT AGGREGATE                      |                        |     1 |     2 |            |       |
    |*  2 |   FILTER                             |                        |       |       |            |       |
    |   3 |    COLLECTION ITERATOR PICKLER FETCH | XMLSEQUENCEFROMXMLTYPE |       |       |            |       |
    |   4 |    NESTED LOOPS                      |                        |   667K|  2606K|   221K  (1)| 00:44:24 |
    |   5 |     COLLECTION ITERATOR PICKLER FETCH| XQSEQUENCEFROMXMLTYPE  |       |       |            |       |
    |*  6 |     COLLECTION ITERATOR PICKLER FETCH| XQSEQUENCEFROMXMLTYPE  |       |       |            |       |
    |   7 |  FAST DUAL                           |                        |     1 |       |     2   (0)| 00:00:01 |
    Predicate Information (identified by operation id):
       2 - filter( EXISTS (SELECT 0 FROM TABLE() "KOKBF$",TABLE() "KOKBF$" WHERE
                  SYS_XQ_UPKXML2SQL(SYS_XQEXVAL(SYS_XQEXTRACT(VALUE(KOKBF$),'/text()'),1,50),50,1,0)=SYS_XQ_UPKXML2SQL(SY
                  S_XQEXVAL(SYS_XQEXTRACT(VALUE(KOKBF$),'/text()'),1,50),50,1,0)))
       6 - filter(SYS_XQ_UPKXML2SQL(SYS_XQEXVAL(SYS_XQEXTRACT(VALUE(KOKBF$),'/text()'),1,50),50,1,0)=SYS_XQ
                  _UPKXML2SQL(SYS_XQEXVAL(SYS_XQEXTRACT(VALUE(KOKBF$),'/text()'),1,50),50,1,0))
    SQL>
    SQL>
    SQL>
    SQL>
    SQL>

  • Urgent: How to get value from Element Node?

    Hi All,
    I have an xml like below:
    <?xml version="1.0"?>     
    <Accounts>
    <Account rowid="1">
    <Account_Id>1</Account_Id>
    <Customer_Id>1</Customer_Id>
    <Account_Type>SB</Account_Type>
    <Balance>1000.00</Balance>
    </Account>
    <Account rowid="2">
    <Account_Id>2</Account_Id>
    <Customer_Id>1</Customer_Id>
    <Account_Type>CD</Account_Type>
    <Balance>1000.00</Balance>
    </Account>
    </Accounts>
    I am trying to get the value in the Account_Id element, but I am getting null everytime. Here is my code:
    import com.sun.org.apache.xerces.internal.impl.xs.dom.DOMParser;
    DOMParser parser = new DOMParser();
    parser.parse("D:\\Temp\\PCORDBMS\\"+tableName+".xml");
    Document doc = parser.getDocument();
    NodeList nodes = doc.getElementsByTagName("Account");
    for(int i=0;i<nodes.getLength();i++) {
    Node fc=nodes.item(i).getFirstChild();
    System.out.println(fc.getNodeValue());
    I think, since fc node is of the type Element - getNodeValue() is not returning the value. I also tried getting child nodes, getting attributes for fc & then getNodeValue.
    Am I missing something? Appreciate your help.
    Thanks,
    Niranjan

    Hi Niranjan,
    I used the JAXP DocumentBuilder and DocumentBuilderFactory classes. I use JSE 5.
    Here's the complete code that works for me:
    package com.trfsol.domtester;
    import javax.xml.parsers.DocumentBuilder;
    import javax.xml.parsers.DocumentBuilderFactory;
    import org.w3c.dom.Document;
    import org.w3c.dom.Node;
    import org.w3c.dom.NodeList;
    public class DomTester {
         * @param args
         public static void main(String[] args) {
              String filename = "C:\\Java workspaces\\Eclipse\\Workspace\\Test\\test.xml";
              try {
                   // Parse XML file
                   DocumentBuilderFactory factory =
                        DocumentBuilderFactory.newInstance();
                   DocumentBuilder parser = factory.newDocumentBuilder();
                   Document document = parser.parse(filename);
                   // Get all "Account" nodes
                   NodeList accountNodes = document.getElementsByTagName("Account");
                   // Iterate over nodes
                   for (int index = 0; index < accountNodes.getLength(); index ++) {
                        NodeList childNodes = accountNodes.item(index).getChildNodes();
                        for (int subIndex = 0; subIndex < childNodes.getLength(); subIndex ++) {
                             Node childNode = childNodes.item(subIndex);
                             System.out.println(childNode.getTextContent());
              catch (Exception e) {
                   System.err.println("Exception: " + e.getMessage());
    Regards, Ronald

  • How to calculate values on Hierarchy node level in WEBI

    Hi Experts
    I have a BI Query ,which have GL account Hierarchy(FSV) Drill down like
    Revenue                            213.15
    Operating Expense       28.49
    Revenue and Operating Expense are two node of the hierarchy ,similarly under these sub node and GL grouping is done in FSV(Hierarchy).
    I need to calculate Operating Expenses % and report look like
    Revenue                             213.15
    Operating Expense       28.49
    Operating Expenses %       13%
    i.e Operating Expences % = Operating Expences /  Revenue *100
    how It will done in Webi rich Client.
    Regards
    Abhi

    Hi,
    You need to work with your Business to understand how these calculations are formulated in their definition, and how they are qualified and quantified.  Next, you have to abstract that logic, and recreate it using the reporting interface of webintelligence.  context is everything.
    This is not something that can easily be explained over a text chat forum!!
    I'd encourage you to work with a colleague who can deliver such reports in BObj,  or,  give it a go yourself using trial and error.
    Regards,
    H

  • How to add value to Root node in message mapping i.e. ns1:sObjects to ns1:sObjects xsi:type="Account"

    Hi Experts,
      please provide me any  UDF or Java or XSLT maaping code to add text into the root node of the payload i.e. my target Payload will be like
    <ns1:sObjects>
    <ns2:Id>123</ns2:Id>
    <ns2:name>Test message <n/s2:name>
    </ns1:sObjects>
    and i have to get it like
    <ns1:sObjects xsi:type="Account">
    <ns2:Id>123</ns2:Id>
    <ns2:name>Test message <n/s2:name>
    </ns1:sObjects>
    Regards,
    Yugandhar

    HI Yugandhar,
    In case of sales force, the can team will provide you a WSDL, In that WSDL you can manually edit the type:Account and can use the same while mapping.
    pls find the below screen shot, it will give you a better idea,
    pls let me know if you any further issues regarding.
    Pls Mark it as a correct answer if it is.
    Thanks,
    Prasad.

  • How to set values to the structure containing a node with cardinality 0..n

    Hello.
    I 'm trying to set values for the node with cardinality 0..n. The node type is "Fields".
    <xsd:complexType name="Field">
       <xsd:sequence>
          <xsd:element name="fieldCode" type="xsd:string"></xsd:element>
          <xsd:element name="displayValue" type="xsd:string" minOccurs="0"></xsd:element>
       </xsd:sequence>
    </xsd:complexType>
    <xsd:complexType name="Fields">
       <xsd:sequence>
          <xsd:element name="field" type="tns:Field" minOccurs="0" maxOccurs="unbounded"></xsd:element>
       </xsd:sequence>
    </xsd:complexType>
    I  need to set several values for the element "fieldCode" but it has cardinality 0..1 and BPM does not allow it but I did not find any option about how to set values for the structure of type "Fields". Could you help me?
    Best regards,
    Timur Semenchuk

    Hi Marcus,
    If there is no way you could change the cardinality of the node, and thus it can contain 0..n items, I think you should create-and-add a new element programmatically.
    Since the collection can contain zero elements, I would add a 'new' button, which upon clicking adds one new element via:
    IYourNodeElement yourNodeElem = wdContext.nodeYourNode().createYourNodeElement();
    wdContext.nodeYourNode().addElement(yourNodeElem);
    Hope this explains a bit!
    Best,
    Robin van het Hof

  • How to edit TCURC values in BI

    Can someone tell me how to edit values in TCURC table?
    (I'm having issues importing it from R3 and I need a quick fix in mean time)
    Thanks

    Just a bit more explanation on what Ravi posted:
    You should go to Customizing transaction SPRO and select the following path:
    SAP NetWeaver   ->General Settings->Currencies->Check currency codes
    That way you can also access the relevant documentation.
    This leads you to the view V_CURC.
    In there you can take advantage of the cross system table viewer to compare with the settings in your R/3 system. To do so select from the menu:
    Utilities->Adjustment (in Change mode)
    Utilities->Comparison (in Display mode)
    Pick the RFC connection to connect to your R/3 system. Use the Filter icon to hide identical records. Select all (Edit->Select->...) and click on Adjust. Copy all and go back confirming the pop up with Yes. That way you can copy over values from R/3 to BW.
    *Note: This tool works on all views that exist in both systems and you can compare and copy data easily.
    Best,
    Ralf

  • How to edit the node value of a tree in webdynpro java

    Hi ALL
    I have Tree UI element where i got displayed all the nodes by calling the BAPI
    Now my requirement is when i put the cursor at any node in the Tree struture then on click of insert button i need to insert the new node with the text  , the user has to be option to give new text for the new node dynamically  , so while adding the new node in a tree the tree has to choose the text for new node , like how to edit the node of a tree to add new text.
    If any one can send the sample code on the same then it would be great help to me.
    Similar requirement like in table UI Like however we are adding the new row in a table when we click on the insert button then cursor will go to that new row in a table where user can enter his details in the table.. now i am looking for the same requirement in a Tree UI element.
    is it possible the same requirement in tree UI element in webdynpro for Java??
    Thanks
    kallki reddy

    Hi kallki reddy
    In general I think this is not possible in the form you'd like. It seems the Tree control is read-only thing always. It cannot provide editing capabilities.
    Table is different thing. You can select within many different cell editors including Input Fields.
    I guess that you scenario could be implemented not with Tree control, but with Table with Master Column. The master column allows to bring up a hierarchy into a plain table. So it's just a tree inside a table.
    Here you can find further details: [TreeByNestingTableColumn API|http://help.sap.com/saphelp_nw70ehp1/helpdata/en/92/12a74046033913e10000000a155106/content.htm]
    BR, Siarhei

  • How to Edit perticular node in XML

    How to edit Perticular XML node ?
    <root>
    <node1>
    <data1>   dsfs  </data1>
    <data2>   dsfs  </data2>
    <data3>   dsfs  </data3>
    <data4>   dsfs  </data4>
    </node1>
    </root>What should i do to change data3 value, means edit data of <data3> ??
    help me

    Retriece data3 node with XPath or DOM. Set node value with setNodeValue() method.

  • How can I get the edited value from the editor in JTable

    I have a JTextField added as an editor to a cell in JTable.
    I value gets changed when I press enter.
    but in actionPerformed of the JTextField when I say
    String txtEditorValue = txtEditor.getText();
    I am getting the old value. How can I get the edited value? Thanks.

    Hi,
    I guess, your understanding of how JTable works together with its models is not good enough - for example the method getTableCellEditorComponent(...) of the TableCellEditor interface is used to get the component, that should be used as editing component - its second parameter is a value that should be used to setup the editing component - it is normally not the editing component itself.
    JTable uses an underlying TableModel to store the cell values - if you have edited a cell, JTable gets the value of the editing component by itself and stores it in the TableModel using its setValueAt(...) method. To retrieve this data you only need to query the TableModel using row and column of this cell as parameters
    say jt is your JTable, and row and column are the row and column of the cell - so to get the value, simply use
    Object obj = jt.getModel().getValueAt(row,column);
    if you know, that there is a String in this cell use
    String str = (String) jt.getModel().getValueAt(row,column);
    The editor component is used for the view of the JTable - you only want the data, which is stored in the model - you don't have to deal with the GUI components in this case.
    greetings Marsian

  • How to get attribute value of a node

    Hi experts
    I have a mapped node in my view context from component controller context. This node consists of 2 value attributes inside
    Example:
    NODE1             -
    > Cardinality 1..1, seleciton 1..1
       -- x_date         -
    > type DATS
       -- x_years        -
    > dec3
    How do I get the attribute value attr1 and attr2 ??
    Here is my code in my view method
      DATA: lr_node_info TYPE REF TO if_wd_context_node_info,
            l_date       TYPE dats,
            l_xyears     TYPE i.
      lr_node_info = wd_context->get_node_info( ).
      lr_node_info = lr_node_info->get_child_node('NODE1').
       l_date       = lr_node_info->get_attribute( name = 'X_DATE' ).
       l_xyears     = lr_node_info->get_attribute( name = 'X_YEARS' ).
    It does not seems to work since it says < the result type of the function method can not be converted into the result type L_DATE>
    I try to understand why but not sucessful, please help and thank you for your kindness

    Hi Dean,
    Regading uour problem of reading the attributes value of the context node, you have to  use the code wizard. that ia avaliable on the top toolbar when you are inside the View Method
    There is option to read context  select that radio button option and then thru F4 help
    if you can select the node then Code is automatically generated with variable declaration.!!
    Like this :
      DATA lo_nd_node1 TYPE REF TO if_wd_context_node.
        DATA lo_el_node1 TYPE REF TO if_wd_context_element.
        DATA ls_node1 TYPE wd_this->element_node1.
        DATA lv_x_date LIKE ls_node1-x_date.
        DATA lv_x_year LIKE ls_node1-x_year.   
      navigate from <CONTEXT> to <NODE1> via lead selection
        lo_nd_node1 = wd_context->get_child_node( name = wd_this->wdctx_node1 ).
      get element via lead selection
        lo_el_node1 = lo_nd_node1->get_element(  ).
      get all declared attributes
        lo_el_node1->get_static_attributes(
          IMPORTING
            static_attributes = ls_node1 ).
        lv_x_date = ls_node1-x_date.
        lv_x_date = ls_noe1-x_year.
    if you can select the attribute then Code is automatically generated with variable declaration.!!
    DATA lo_nd_node1 TYPE REF TO if_wd_context_node.
      DATA lo_el_node1 TYPE REF TO if_wd_context_element.
      DATA ls_node1 TYPE wd_this->element_node1.
      DATA lv_x_date LIKE ls_node1-x_date.
    navigate from <CONTEXT> to <NODE1> via lead selection
      lo_nd_node1 = wd_context->get_child_node( name = wd_this->wdctx_node1 ).
    get element via lead selection
      lo_el_node1 = lo_nd_node1->get_element(  ).
    get single attribute
      lo_el_node1->get_attribute(
        EXPORTING
          name =  `X_DATE`
        IMPORTING
          value = lv_x_date ).
    Hopes this will helps you.
    Regard
    Manoj Kumar

Maybe you are looking for

  • Iphone 5 won't sync to iTunes on MacBook Pro.  HELP

    Everytime I plug my iPhone 5 into my Mac to try to sync it to iTunes this message shows up, "Do you want to allow this computer to access information on "Emily's iPhone"? If you dont allow access, you will not be able to manage or sync your iPhone wi

  • Fndload error while downloading a profile

    Hi, Can any one help out with downloading a profile using fndload. I am following the exact syntax but the afscprof.lct fails with the following error. Column 2 in the select list is too large for LEVEL_VALUE in entity FND_PROFILE_OPTION_VALUES The e

  • Replicating windows trackpad gesture in OS-X - drag to edge

    While the Mac Trackpad is superior in almost every way, there is one missing feature I loved on my Dell Laptop (Windows 7).  It is hard to describe, and thus, hard to search for info on. Basically, on my windows touchpad, I can tap and drag an object

  • Automate MySQL database dump

    Hello All, I am fairly new to Unix administration,OS X in particular. I am in need of opinions for the easiest wasy to automate a command to dump a MySQL database on a rotating weekly basis. I only want 7 days worth of dumps to reside there. I have b

  • Error when trying to change the Query in Bex??

    Hi Gurus, I have a query based on infocube. When I am trying to change the query, its giving me the error "This component was edited with a more recent version of Editor. You also have to use the more recent version to edit further. Further processin