Dynamic Node Creation

Hai all,
          I am new to the Dynpro. i have to create 'n' number of drop down at dynamically. The values of 'n' only known at runtime, that is fetch from database. 
          Basically each dropdown must have one node and one attribute. So i have to create 'n' number of nodes. Each drop down have different values.
           I created some node at runtime using the following code.
      for(int j=0;j<count;j++){
      IWDNodeInfo node = wdContext.getNodeInfo
      ().addChild ("Roles"+j,null,true,     true,false,
      false,false,true,null,null,null);
      node.addAttribute(roles[j].toString  
      (),"com.sap.dictionary.string");
This is done inside the wdDoInit() method.
Then i have to fetch the node one by one and load values from database and finally bind into the drop down inside the wdDoModifyView() method.
      I tried the following code,but i don't know whether is it correct way or not.
if (firstTime) {
          IWDTransparentContainer container = 
                (IWDTransparentContainer) view.getElement
                ("RootUIElementContainer");
container.createLayout(IWDMatrixLayout.class);
for(int rolecunt=0;rolecunt<size;rolecunt++){
IWDNode node = wdContext.currentContextElement().node().getChildNode("Roles"+rolecunt,rolecunt);
IWDNodeElement nodeElement1 = node.getCurrentElement();
thanks in advance,
Mukesh Mani.

Hai Noufal,
            Thanks for your reply. I couldn't get you. From your suggestion i created dropdown only in domodify() like this,
IWDDropDownByIndex dropDownList = (IWDDropDownByIndex)
view.createElement (IWDDropDownByIndex.class, "inp");
            How to bind node attribute into the above drop down. Before i created 'n' number of nodes in
wdinit() method using the following code.
for(int j=0;j<count;j++){
               IWDNodeInfo node =
                           wdContext.getNodeInfo().addChild(
                              "Roles"+j,
                              null,
                              true,
                              true,
                              false,
                              false,
                              false,
                              true,
                              null,
                              null,
                              null);
//                    for(int k=0;k<count;k++){          
                         node.addAttribute(roles[j].toString(),"com.sap.dictionary.string");

Similar Messages

  • Dynamic node creation from RTTI structure and dynamic mapping

    Hi,
    I'd like to create a dynamic node in my component controller then map this node to a node in my view and bind it to a dynamic table.
    I create the dynamic node in my component controller using the add_new_child_node method :
    CALL METHOD root_node_info->add_new_child_node
        EXPORTING
          name                    = 'MY_TABLE'
          static_element_rtti     = struct_type
          is_static               = ABAP_true
        RECEIVING
          child_node_info              = node_info
    Then I use the add_new_mapped_child_node method to map the node in the view :
    * Map the context node dynamically
      wa_path = 'COMPONENTCONTROLLER.MY_TABLE'.
      insert wa_path into table tab_mapping_path.
      stru_mapping_info-controller = 'COMPONENTCONTROLLER'.
      stru_mapping_info-path = tab_mapping_path.
      lo_node_info = wd_context->get_node_info( ).
      CALL METHOD lo_node_info->add_new_mapped_child_node
        EXPORTING
          child_name      = 'MY_TABLE'
          mapping_info    = stru_mapping_info
        receiving
          child_node_info = lo_dyn_node_info
    The child node is created in my view context but it doesn't have any attribute or static element RTTI.
    Do I have to add each attribute with the add_attribute method and then the add_new_mapped_child_node method will copy them over?
    Regards,
    Pierre

    Problem solved, the path was not good :
    * Map the context node dynamically
    *  wa_path = 'COMPONENTCONTROLLER.MY_TABLE'.
    *  insert wa_path into table tab_mapping_path.
      stru_mapping_info-controller = 'COMPONENTCONTROLLER'.
    *  stru_mapping_info-path = tab_mapping_path.
      append 'COMPONENTCONTROLLER' to stru_mapping_info-path.
      append 'MY_TABLE' to stru_mapping_info-path.
      lo_node_info = wd_context->get_node_info( ).
      CALL METHOD lo_node_info->add_new_mapped_child_node
        EXPORTING
          child_name      = 'MY_TABLE'
          mapping_info    = stru_mapping_info
        receiving
          child_node_info = lo_dyn_node_info
    Regards,
    Pierre

  • Error in dynamic node creation ..........

    Hi experts,
    I am creating a node dynamically in WDDOINT  and creating an input field in WDDOMODIFYVIEW , but am getting an error "attribute not found". Am pasting below my code...
    Code in WDDOINT of a view :
    data lr_par_node       type ref to IF_WD_CONTEXT_NODE_INFO.
        data lr_node       type ref to IF_WD_CONTEXT_NODE_info.
         data lr_node_info1       type ref to IF_WD_CONTEXT_NODE_INFO.
        data lr_node1       type ref to IF_WD_CONTEXT_NODE.
        data lr_attribute  type        WDR_CONTEXT_ATTRIBUTE_INFO.
        data lt_child_node_map                  type wdr_context_child_info_map.
    *****to get context parent node information
        lr_par_node = wd_context->get_node_info( ).
    *****to get child node of the parent
        lt_child_node_map = lr_par_node->get_child_nodes( ).
    *****check for the existence of node
        read table lt_child_node_map transporting no fields with table key name = `RESULT`.
        if sy-subrc = 0.
          " REMOVE_CHILD_NODE
          lr_par_node->remove_child_node( `RESULT` ).
        endif.
    *****inserting new node in context
        CALL METHOD lr_par_node->ADD_NEW_CHILD_NODE
          EXPORTING
            NAME                         = 'RESULT'
    *       IS_MANDATORY                 = ABAP_FALSE
    *       IS_MANDATORY_SELECTION       = ABAP_FALSE
            IS_MULTIPLE                  = ABAP_TRUE
           IS_MULTIPLE_SELECTION        = ABAP_TRUE
    *       IS_SINGLETON                 = ABAP_FALSE
           IS_INITIALIZE_LEAD_SELECTION = ABAP_false
    *       STATIC_ELEMENT_RTTI          =
            IS_STATIC                    = ABAP_TRUE
    *       ATTRIBUTES                   =
    *       IS_RANGE_NODE                =
          RECEIVING
            CHILD_NODE_INFO              = lr_node.
        lr_node1 = wd_context->get_child_node( name = 'RESULT' ).
        lr_node_info1 = lr_node1->GET_NODE_INFO( ).
    *********Adding attribute
        lr_attribute-NAME = 'TEST_GROUP'.
        lr_attribute-TYPE_NAME = 'PLNNR'.
        lr_attribute-NODE_INFO = lr_node_info1.
        CALL METHOD lr_node_info1->ADD_ATTRIBUTE
          EXPORTING
            ATTRIBUTE_INFO = lr_attribute.
        clear lr_attribute.
    Code in the WDDOMODIFYVIEW :
    method WDDOMODIFYVIEW .
      if first_time = abap_true.
        data : lt_header_block type zcdp_tt_mfte_header.
        lt_header_block = WD_COMP_CONTROLLER->MT_HEADER_BLOCK.
        DATA :lr_container  TYPE REF TO cl_wd_uielement_container,
         lr_input      TYPE REF TO cl_wd_input_field,
         lr_caption    type ref to CL_WD_CAPTION,
         lr_column type ref to CL_WD_TABLE_COLUMN,
         lr_trans_cont TYPE REF TO CL_WD_TRANSPARENT_CONTAINER.
        data lr_lbl type ref to CL_WD_TEXT_VIEW.
    ******to get root element container
        lr_container ?= view->get_element( 'ROOTUIELEMENTCONTAINER' ).
        lr_trans_cont ?= VIEW->GET_ELEMENT('TRANS_CONT_HEADER_BLOCK').
    * Created one transparent container in the view.......
    CALL METHOD CL_WD_TEXT_VIEW=>NEW_TEXT_VIEW
      EXPORTING
    *    CONTEXT_MENU_BEHAVIOUR = E_CONTEXT_MENU_BEHAVIOUR-INHERIT
    *    CONTEXT_MENU_ID        =
    *    DESIGN                 = E_DESIGN-STANDARD
    *    ENABLED                = 'X'
    *    H_ALIGN                = E_H_ALIGN-AUTO
    *    ID                     =
    *    LAYOUT                 = E_LAYOUT-NATIVE
    *    SEMANTIC_COLOR         = E_SEMANTIC_COLOR-STANDARD
        TEXT                   = 'TEST'
    *    TEXT_DIRECTION         = E_TEXT_DIRECTION-INHERIT
    *    TOOLTIP                =
    *    VIEW                   =
    *    VISIBLE                = E_VISIBLE-VISIBLE
    *    WIDTH                  =
    *    WRAPPING               =
      RECEIVING
        CONTROL                = lr_lbl
    cl_wd_matrix_head_data=>new_matrix_head_data(
                element = lr_lbl ).
    lr_trans_cont->ADD_CHILD( lr_lbl ).
       CALL METHOD CL_WD_INPUT_FIELD=>NEW_INPUT_FIELD
          EXPORTING
            BIND_VALUE             = 'RESULT.TEST_GROUP'
            ENABLED                = 'X'
    *       EXPLANATION            =
           ID                     = 'ABCD'
          RECEIVING
            CONTROL                = lr_input.
      cl_wd_matrix_data=>new_matrix_data(
                element = lr_input ).
    lr_trans_cont->ADD_CHILD( lr_input ).
      endif.
    endmethod.
    Pls help  me in this.....
    Thanks
    Aisurya.

    Hi,
    looking at code it seems that you are adding textview and inputfield. please check in debugging if the correct context node/attribute  is being created and you are providing its reference while adding UI elements.
    Thanks,
    Chandra

  • Dynamic node Creation Problem

    Hi all,
    I am trying to create a node through Java code bellow is the code
    IWDNodeInfo graph = wdContext.nodeGraph().getNodeInfo();
    for(int i=0;i<10;i++)
         int nodeNumber = i+4;
         IWDNodeInfo seriseNode = graph.addChild("Serise"+nodeNumber,null,true,false,false,false,false,false,null,null,null);
         seriseNode.addAttribute("S"+nodeNumber+"_size","com.sap.dictionary.double");
         seriseNode.addAttribute("S"+nodeNumber+"_xVal","com.sap.dictionary.double");
         seriseNode.addAttribute("S"+nodeNumber+"_yVal","com.sap.dictionary.double");
         //seriseNode.addAttribute("S"+nodeNumber+"_tooltip","com.sap.dictionary.string");
         IWDNode node = wdContext.nodeGraph().getChildNode("Serise"+nodeNumber,IWDNode.NO_SELECTION);
         IWDNodeElement nodeElem = node.createElement();
         nodeElem.setAttributeValue("S"+nodeNumber+"_xVal",new Double(0));
         nodeElem.setAttributeValue("S"+nodeNumber+"_yVal",new Double(0));
         nodeElem.setAttributeValue("S"+nodeNumber+"_size",new Double(0));
         node.addElement(nodeElem);
    IWDNode node = wdContext.nodeGraph().getChildNode("Serise4",IWDNode.NO_SELECTION);
    node.getCurrentElement().getAttributeAsText("S4_size");
    now it is giving me null pointer exception at last line any idea why it coming.
    Thanks

    Hi,
    This problem is solved but now there is another problem,
    I am creating a Node and attributes at runtime and want to bind to a business graphics UI element bellow is the code for that
    IWDPoint se_point = (IWDPoint) view.createElement(IWDPoint.class,"Series"+seriseNumber+"_Point");
    se.setPoint(se_point);
    se.getPoint().bindValueSource("Graph.Serise"+seriseNumber);
    se.setLabel(supp.getSupplier_Name());
    IWDNumericValue numXVal = (IWDNumericValue) view.createElement(IWDNumericValue.class,"S_"+seriseNumber+"numXVal");
    numXVal.bindValue("Graph.Series"+seriseNumber+".S"+seriseNumber+"_xVal");
    numXVal.setType(WDValueTypeEnumeration.X);
    numXVal.setValue(supp.getXcord());
    and it gives bellow error for last line in the code
    com.sap.tc.webdynpro.progmodel.context.ContextException: Node(GraphView.Graph): no child node 'Series1' at index -1
    Can any one help in this
    Thanks

  • Dynamic Node bind to attribute of type "STRING_TABLE"

    Hi ,
    I want to create dynamic node which is bind to attribute of type "STRING_TABLE'.
    Basically I want to create this node for inserting dynamic "TEXT EDIT' UI elements in my view .
    can sm1 help me in this regard.

    Seems like you should be able to use the API: cl_wd_dynamic_tool=>create_nodeinfo_from_struct.
    The real question is do you really need to create the node dynamically.  Why not just create a node that has the string_table attribute in it. Make the node 1:n or 0:n.  Bind this node to a RowReapter or MultiPane UI element.  Then as a child of the RowReapter/MultiPane you place your textEdit UI element.  This way, you will render dynamically how ever many textEdits as there are elements in your node.  No need for dynamic node creation.

  • Problem with Dynamic Node & UI Elements

    Hi,
                                            The scenario is to create an Questioaire.Since the number questions which I get from R/3 may vary, I have created the Dynamic Node which is mapped with Dynamic set of Radio button Group by index for options & Dynamic text view for displaying Questions..  A New Dynamic Node will be created for each set of Questions .The Number of questions displayed per page is controlled by the Static Counter Variable....
                                              Now the issue is ,if i click back button the count will be initialized so again it needs to trigger the DoModifyView(). at that time It is arising an exception "Duplicate ID for view & Radio button ..." because while creating Dynamic node i used to have "i" value along the Creation of node name...
    for(i=Count;i<i<wdContext.nodeQuestions().size();i++)
                   customnod=<b>nodeinfo.getChild("Questionaire"+i);</b>
                        if(customnod==null)
    Its not possible to create a new node whenever i click the Back button.
    At the same time i am not able to fetch the elements which had already created Dynamically...
    How do i make the Next & back button work?
    If anyone  bring me the solution It would be more helpful to me.
    Thanks in advance..
    Regards,
    Malar

    Hi,
          We can Loop through the Node Elements but how can we do Option Button Creation for each set of question Options?. At design time we can not have the radio buttons,because we do not know how many set of questions are available at the Backend.

  • Reading XML file into Dynamic Node and Display its output as Table.

    Hi All,
    Following is the output of XML file:
       <Company>
         <Employee>
              <Name>John</Name>
              <Age>23</Age>
              <***>Male</***>
              <Location>Frankfurt</Location>
         </Employee>
         <Employee>
              <Name>Tina</Name>
              <Age>21</Age>
              <***>Female</***>
              <Location>Boston</Location>
         </Employee>
         <Department>
              <Name>Sales</Name>
              <HQ>Chicago</HQ>
              <Emplyoees>2300</Employees>
         </Department>     
    I'm able to read the output through DOM parser. But How do I convert this into dynamic node and display this in Web dynpro as Table?
    Any pointers in this regard will be great help?
    Thanks
    Srikant

    Hi Maksim,
    I've used your example and its now helping as there is kind of agreement on that I'll be knowing the structure of Xml and I can fill the nodes.
    But suppose if you have Xml has following structure :
    <?xml version="1.0" encoding="utf-8"?><DATA>
    <item><MAILERID TYPE="C" SIZE="000030">21</MAILERID><ORG_CODE TYPE="C" SIZE="000004">1232</ORG_CODE><EVENTID TYPE="C" SIZE="000015">CONTRACT</EVENTID><SUBSCR_VALUE TYPE="C" SIZE="000001">0</SUBSCR_VALUE></item>
    <item><MAILERID TYPE="C" SIZE="000030">21</MAILERID><ORG_CODE TYPE="C" SIZE="000004">1232</ORG_CODE><EVENTID TYPE="C" SIZE="000015">CREDIT</EVENTID><SUBSCR_VALUE TYPE="C" SIZE="000001">0</SUBSCR_VALUE></item>
    <item><MAILERID TYPE="C" SIZE="000030">21</MAILERID><ORG_CODE TYPE="C" SIZE="000004">1232</ORG_CODE><EVENTID TYPE="C" SIZE="000015">EMPRESS</EVENTID><SUBSCR_VALUE TYPE="C" SIZE="000001">0</SUBSCR_VALUE></item>
    <item><MAILERID TYPE="C" SIZE="000030">21</MAILERID><ORG_CODE TYPE="C" SIZE="000004">1232</ORG_CODE><EVENTID TYPE="C" SIZE="000015">PAYMENT</EVENTID><SUBSCR_VALUE TYPE="C" SIZE="000001">0</SUBSCR_VALUE></item>
    <item><MAILERID TYPE="C" SIZE="000030">21</MAILERID><ORG_CODE TYPE="C" SIZE="000004">1232</ORG_CODE><EVENTID TYPE="C" SIZE="000015">PRICE</EVENTID><SUBSCR_VALUE TYPE="C" SIZE="000001">0</SUBSCR_VALUE></item>
    </DATA>
    How we will do in this case?
    Can we have something similar using DOM? Also what is the best method for displaying data being sent in form of XML. And generalize it for cases like this.
    Thanks
    Srikant

  • Creating a Dynamic Node for a Dynamic Graphic - Tutorial

    Hi everyone,
    I'm sharing my first tutorial, hope it'll be helpful for you.
    In the Layout tab, it's possible to create an UI element "Business Graphic". It's a very simple tool that only requires a context node with a category attribute (that means, the values that will appear in the 'x' axis) and one or more series (each one with a color, generally a numerical value). It's possible to add a label for each series for better understanding of the Graphic.
    Although it's a very powerful tool, there are some problems when we must create a graphic with N series and different labels. If the graphic use an ALV or internal table to fetch data, during runtime we can have more or less series. The definition of a static node and generic series is not enough in this case. That's why I'd like to present you this little tutorial to create a dynamic node that fetchs a dynamic graph:
    In the WDDOINIT or Event Handler method that starts the application (once the data is available) we should create the dynamic node in the following way:
      DATA: lr_node_info    TYPE REF TO if_wd_context_node_info,             
                 lt_attributes      TYPE cl_abap_structdescr=>component_table,
                 attribute           LIKE LINE OF lt_attributes,
                 struct_type       TYPE REF TO cl_abap_structdescr,
                 lo_dyn_node    TYPE REF TO if_wd_context_node.
    * Let's suppouse we can LOOP at the data table, so we can fetch the
    * category data type (for example company name, month, year, ...)
    * and each series with a numeric type
      attribute-name = 'CATEGORY'.
      attribute-type ?= cl_abap_datadescr=>describe_by_name( 'STRING' ).
      INSERT attribute INTO TABLE lt_attributes.
      attribute-name = 'SERIE1'.
      attribute-type ?= cl_abap_datadescr=>describe_by_name( 'I' ).
      INSERT attribute INTO TABLE lt_attributes.
      attribute-name = 'SERIE2'.
      attribute-type ?= cl_abap_datadescr=>describe_by_name( 'I' ).
      INSERT attribute INTO TABLE lt_attributes.
    * Once we have all the attributs for the node, we create a formal structure
      struct_type = cl_abap_structdescr=>create( lt_attributes ).
    * Now we can get the context information to add a new node
      lr_node_info = wd_context->get_node_info( ).
    * Create the node
      lr_node_info = lr_node_info->add_new_child_node(
                        name = 'GRPH_DYN'
                        IS_MANDATORY = ABAP_false
                        IS_MULTIPLE = ABAP_true
                        STATIC_ELEMENT_RTTI = struct_type
                        IS_STATIC = ABAP_false ).
    * Now we should populates the node, I'll create a hardcoded table,
    * simulating the internal table that you should already have
      TYPES: BEGIN OF tw_alv,
                        category  TYPE string,
                       SERIE1    TYPE i,
                       SERIE2    TYPE i,
                    END OF tw_alv.
      TYPES: tt_alv TYPE STANDARD TABLE OF tw_alv.
      DATA: lw_alv  TYPE tw_alv,
                  lt_alv   TYPE tt_alv.
      lw_alv-category = 'Alfa'.
      lw_alv-serie1   = 3.
      lw_alv-serie2   = 8.
      APPEND lw_alv TO lt_alv.
      lw_alv-category = 'Beta'.
      lw_alv-serie1   = 4.
      lw_alv-serie2   = 4.
      APPEND lw_alv TO lt_alv.
      lw_alv-category = 'Gamma'.
      lw_alv-serie1   = 1.
      lw_alv-serie2   = 3.
      APPEND lw_alv TO lt_alv.
    * Now let's call the recently created node and bind the lt_alv table.
    * Get node from context
      lo_dyn_node = wd_context->get_child_node( name = 'GRPH_DYN' ).
    * Bind table with ALV Container
      CALL METHOD lo_dyn_node->bind_table
        EXPORTING
          new_items = lt_alv.
    * It's always good to check if the table was succesfully binded.
    * I refresh the lt_alv table and get the values from the node for controlling
      REFRESH lt_alv.
      lo_dyn_node->get_static_attributes_table( IMPORTING table = lt_alv ).
    There are other ways of adding a node structure in the method add_new_child_node, but it works for me only with STATIC_ELEMENT_RTTI. The node is now created and has the data required for the graphic. Now, we should go to WDDOONMODIFYVIEW, or save the target view as a parameter, to create the graphic, bind the category and series and show it on the screen.
      DATA: lr_graph       TYPE REF TO cl_wd_business_graphics,
                  lr_cat           TYPE REF TO cl_wd_category,
                  lr_series1    TYPE REF TO cl_wd_simple_series,
                  lr_series2    TYPE REF TO cl_wd_simple_series,
                  lr_container TYPE REF TO cl_wd_uielement_container,
                  lr_flow         TYPE REF TO cl_wd_flow_data.
    * Get the root element from the Layout or the specific
    * container you have created for the graphic
      lr_container ?= view->get_element( 'ROOTUIELEMENTCONTAINER' ).
    * Creates a line busniess graph
      lr_graph = cl_wd_business_graphics=>new_business_graphics(
            BIND_SERIES_SOURCE = 'GRPH_DYN'
            CHART_TYPE = cl_wd_business_graphics=>e_chart_type-lines
            HEIGHT = 340
            WIDTH = 750
            ID = 'GRAPH'  ).
    * Create the flow data for the new UI Element business graphic
      lr_flow = cl_wd_flow_data=>new_flow_data( element = lr_graph ).
    * Set graph in the root container from the Layout tab
      lr_container->add_child( lr_graph ).
    * Bind the category from the dynamic node to the dynamic graphic
      lr_cat = cl_wd_category=>new_category(
                      view = view
                      bind_description = 'GRPH_DYN.CATEGORY'
                      tooltip = 'Company Name' ).
      lr_graph->set_category( lr_cat ).
    * Bind the two series from the dynamic node to the dynamic graphic
      lr_series1 = cl_wd_simple_series=>new_simple_series(
                      bind_value = 'GRPH_DYN.SERIE1'
                      label = 'Sales'
                      view = view
                      tooltip = 'Average Sales' ).
      lr_graph->add_series( lr_series1 ).
      lr_series2 = cl_wd_simple_series=>new_simple_series(
                      bind_value = 'GRPH_DYN.SERIE2'
                      label = 'Purchases'
                      view = view
                      tooltip = 'Average Purchases' ).
      lr_graph->add_series( lr_series2 ).
    Finally we have created our business graphic. Test the application and you'll see something like the attached image.
    Hope you'll find it useful.
    Daniel Monteros.

    Hi,
    http://htmldb.oracle.com/pls/otn/f?p=26372
    then ApEx>Trees and pick a level.
    Use Help for more information.
    I you think that tree could help I will put more explanation into help page.
    Konstantin

  • How to deal with the dynamic nodes ...in webdynpro abap

    Hi Guys,
    How to insert the dynamic nodes in the context controller...
    Thanks
    Chandra

    You can use node_info to create a dynamic node or use CL_WD_DYNAMIC_TOOL to create dynamic nodes under a node
    For Eg Struc_Node
    fields A type char20,
    fields B type char 20
    For Eg : To Create Node under Context Node( Root Node).
    data lv_node_info type ref to if_wd_context_node_info.
    lv_node_info = wd_context->get_node_info( ).
    CALL METHOD lv_node_info->add_new_child_node
    EXPORTING
    static_element_type = 'Struc_node
    name = lv_node_name
    is_static = abap_false
    is_multiple_selection = abap_true
    RECEIVING
    child_node_info = lv_child_node_info.
    or
    CL_WD_DYNAMIC_TOOL=>CREATE_NODEINFO_FROM_STRUCT

  • Dynamic Table Creation & Fill Up

    Hello,
    Can anyone please guide where I can find examples for dynamic table creation (programmaticaly), with dynamic number of columns and rows, used to place inside text components (or whatever) to fill them with data.
    All programmatic.
    Using JSF, ADF BC
    JDeveloper 10.1.3.1
    Thanks
    Message was edited by:
    RJundi

    Hi,
    Meybe this article helps: http://technology.amis.nl/blog/?p=2306
    Kuba

  • Dynamic Node reset/clear

    Hi All,
    I have generated the context node dynamically and need to reset the node conditionally.  I have other nodes apart from dynamically created node in my context. All these nodes have data when I create my dynamic node. On certain condition, I regenerate this node and want the data in the other nodes to exist. Is there a way to clear the dynamic node only?
    I tried the following without success:
         wdContext.nodeDynamicNode().getContext().reset(false);
         IWDNodeInfo node = wdContext.getContext().getRootNode().getNodeInfo().getChild("DynamicNode");
         wdContext.nodeDynamicNode().bind(wdContext.nodeDynamicNode().createDynamicNodeElement());
    The "DynamicNode" is declared at the design time to which the node elements are added at the runtime. I just want to clear the nodes added before I regenerate the new ones.
    Any tips?
    Thanks in advance.
    Regards,
    Hemanth

    hi......
    As far as I know......
    U can not reset the 1 particular node... if u try whole dynamically created context will be deleted......
    try invalidate() function.......
    jaya

  • How to refer dynamic node?

    Hi All
    I create dynamic table with dynamic node.  Table has one row, and one of the column is Button, if i click on this button i want to add on more empty row of same structure as above row with some changes. If we declare node in context for adding row we follow this code...
    data: lr_node type ref to if_wd_context_node,
    ls_struc type if_main_view=>element_nomenclature.
    lr_node = wd_context->get_child_node( if_main_view=>wdctx_nomenclature ).
    lr_node->bind_element( new_item = ls_struc set_initial_elements = abap_false ).
    But here i  create node dynamycally.  how to refer dynamic node, and how to create row??
    Thanks,
    Madhan.

    Use
    data lr_element type ref to if_wd_context_element.
    lr_element = lr_node->create_element(  ).
    lr_node->bind_element( new_item = lr_element set_initial_elements = abap_false ).
    thanks
    sarbjeet singh

  • Create Multiple dynamic Node in Web Dynpro Abap

    Hi Friends,
          I need your help.My object is to create Multiple dynamic dropdown UI element.I am able to create this dynamic Dropdown element. But i need to assign default different values to this dropdown elements.So i created dynamic nodes for each dropdown and created attribute with same name as that of value table.
       My issue is its giving me error as : -
    Lower-Level Node with Name ZDCN_BRD_STATUS.ME Does Not Exist
    Help me to rectify this error..
    Regards,
    Santosh

    Hi,
    This information is not enough for anybody to help you. Write more in detail about your code and where exactly in the code this error is coming.
    One trial experiment can be that you split your problem into two or more level.
    Create several nodes in your context with attribute and sample data.
    Create Dynamic UI (DDBI) and Bind these attributes to your DDBI.
    When it works perfectly, then tryout how to create the Node and attribute dynamically. This way you are not making it too complex to solve this problem.

  • Does Seeburger's SFTP adapter support dynamic filename creation

    Hi all,
    Does the SFTP adapter support dynamic filename creation.
    If yes, then do we have to use UDF's and are there any specific settings that have to be done in the SFTP communication channel.
    Please provide a blog which helps in the configuration process of the above case.
    thanks,
    younus

    Dynamic Creation of File using counter in Seeburger Variable:
    1. Configuration Needed in the Communication Channel:
    The process of dynamic creation of files can be done we have to select the following checkbox in the receiver channel:
    Dynamic Attribute in receiver Channel:
    Import the following modules:
    Localejbs/Seeburger/solution/sftp
    Localejbs/Seeburger/AttribMapper
    Localejbs/ModuleProcessorExitBean
    Enter  the desired file naming convention:
    Use the Parameter GetCounter("ID") to the place where the counter is expected to come.
    2. Configuration Needed in the SeeBurger Workbench:
    If the J2EE server is listening on a port different from 50000 (which is the standard for the SAP client 000), the port number must be configured:
    Login into the seeburger workbench using the URL
    http://<localhost>:<port number>/seeburger/index.html
    Select Property Store.
    Create or edit the following property:
    Parameter
    Value
    Namespace
    http://seeburger.com/xi/SeeFunctions
    Key
    provider.servlet.server
    Value
    http://localhost:50000/ (where the port number 50000 must be set
    accordingly to the J2EE server configuration).
    Note: The configured value (server URL) has to end with a slash (/). Otherwise,
    SeeFunctions will not work correctly.
    If we need to start the counter from any specific value , it can be configured in the SeeBurger workbench, this value can be maintained in Mapping Variables :

  • How to Export to Excel a Dynamic Node?

    Hi all,
    I would to know how it's possible to export in Excel a dynamic Node, created in the wdDoModify() method.
    I'd seen the tutorial TutWD_ExcelExport in wich the public method for exportation into Excel 2003 accepts in input a IWDNode attribute, but I can't pass him a dynamic node that I'd created and manipulated in the wdDoModify() method.
    How can I do???
    Thanks to all.
    Gianluca Barile

    I've implemented the following code (but it doesn't work)
    in wdDoModify() method:
    IWDNodeInfo nodeinfo = wdContext.getNodeInfo();
    IWDNodeInfo grigliaComparativaNode = nodeinfo.addChild("GrigliaComparativa",null,true,true,true,false,false,true,null,null,null);
    IWDAttributeInfo nominativo = grigliaComparativaNode.addAttribute("Nominativo","com.sap.dictionary.string");
    IWDAttributeInfo periodoDa = grigliaComparativaNode.addAttribute("Da","com.sap.dictionary.string");
    IWDAttributeInfo periodoA = grigliaComparativaNode.addAttribute("A","com.sap.dictionary.string");
    IWDAttributeInfo[] v = new IWDAttributeInfo[50];
    for (int i = 0; i < wdContext.nodeT_Body_Elements().size(); i++)
    v<i> = grigliaComparativaNode.addAttribute("V"+i,"com.sap.dictionary.string");
    IWDNode dynTabNode = (IWDNode)wdContext.getChildNode("GrigliaComparativa",0);
    Map columnInfosMap = new HashMap(); 
    dynTabNode.moveFirst();
    do{
    IWDNodeElement dynTabElem = (IWDNodeElement)dynTabNode.getCurrentElement();
                   columnInfosMap.put(dynTabElem.getClass().getName(),dynTabElem.getClass().getName().toString());
              }while(dynTabNode.moveNext()!=null);
              wdThis.wdGetExcelExportCompInterface().exportToExcel2003(dynTabNode , columnInfosMap);
    Message was edited by: Gianluca Barile
    Message was edited by: Gianluca Barile

Maybe you are looking for