How to create a button with javascript

Hello everyone ,
I'm pretty new in the world fo APEX , after reading a lot of tutorials , i'm trying to build my own application ,but now i'm stuck because of my lack of knowledge :)
So here is the problem ,
I have a line with a select list ( designed to select a task )+ 5 text fields ( designed to write how many hours the worker worked each day for the task )
And then , a button " Add Task " , so with this button i want to create a copy of the first line so the worker can add an other task , but actually i have no idee how to do this .. I don't know if i was clear or not ? ,
I will apreciated all advice and remarks ,
Thanks in advance
Brice

Once your tabular form is created,
go to Report Attributes and click the edit icon(pencil image) next to the column you want to be a select list,
go to column attributes and click the Display As select list, and you'd probably choose Select List Static or Named
The Add Task button would be the standard 'Add Row' button that gets created from creation of the tabular form.
What do the rows that you want to create relate to? It seems that the first row has a Task coming from the select list and the 5 entry columns as hours each working day of week and one week = one row ?
If you need to create additional blank rows, I would look at using an Apex Collection, created in a before header process, where you can add as many rows as desired, then query the collection for the tabular form, and maybe have a custom post submit process to update the collection data to your table. If you're only adding rows to the table, you don't really need the checksum functionality that is a desirable part of the Apex Tabular Form/MRU process. Thinking out loud here.
Hope this helps.
Edited by: Bob37 on Nov 9, 2011 10:40 AM

Similar Messages

  • How to create a button with the drop-down menu?

    I want to create a button with the drop-down menu, which is like the 'back' on the tollbar in IE. I heard JPopupMenu can reach the certain result, but the button hadn't a down arrow. Who can help me?

    i have made something like this :
    //======================================================================
    package com.ju.guiutils
    import java.awt.*;
    import java.awt.event.*;
    import java.net.URL;
    import java.util.Vector;
    import javax.swing.*;
    import javax.swing.border.*;
    import javax.swing.event.*;
    import javax.swing.plaf.basic.BasicComboBoxUI;
    * @version 1.0 14/04/02
    * @author Syed Arshad Ali <br> [email protected]<br>
    * <B>Usage : </B> ButtonsCombo basically performs function button + JComboBox, if we have different options for
    * <BR>same button then we can use this ButtonsCombo.
    *<BR> By the way there is no button at all in <I>ButtonsCombo</I>
    public class ButtonsCombo extends JComboBox {
    //===================================================================================
    * Create ButtonsCombo with default combobox model
    public ButtonsCombo () {
    super ();
    init ();
    //===================================================================================
    * Creates a ButtonsCombo that takes it's items from an existing ComboBoxModel.
    public ButtonsCombo ( ComboBoxModel model ) {
    super ( model );
    init ();
    //===================================================================================
    * Creates a ButtonsCombo that contains the elements in the specified array.
    public ButtonsCombo ( Object [] items ) {
    super ( items );
    init ();
    //===================================================================================
    * Creates a ButtonsCombo that contains the elements in the specified Vector.
    public ButtonsCombo ( Vector items ) {
    super ( items );
    init ();
    //===================================================================================
    private void init () {
    setBorder ( BorderFactory.createBevelBorder ( BevelBorder.RAISED ) );
    setRenderer ( new ComboRenderer() );
    setUI ( new ComboUI() );
    addMouseListener ( new ComboMouseListener() );
    //===================================================================================
    * Set items for ButtonsCombo in the specified array
    public void setItems ( Object [] items ) {
    setModel ( new DefaultComboBoxModel( items ) );
    //```````````````````````````````````````````````````````````````````````````````````
    * Set items for ButtonsCombo in the specified Vector
    public void setItems ( Vector items ) {
    setModel ( new DefaultComboBoxModel( items ) );
    //```````````````````````````````````````````````````````````````````````````````````
    * Get current items in a array
    public Object [] getItemsArray () {
    ComboBoxModel model = this.getModel ();
    if ( model != null ) {
    int size = model.getSize ();
    if ( size > 0 ) {
    Object [] items = new Object[ size ];
    for ( int i = 0; i < size; i++ ) {
    items[ i ] = model.getElementAt ( i );
    return items;
    return null;
    //```````````````````````````````````````````````````````````````````````````````````
    * Get current items in a Vector
    public Vector getItemsVector () {
    ComboBoxModel model = this.getModel ();
    if ( model != null ) {
    int size = model.getSize ();
    if ( size > 0 ) {
    Vector itemsVec = new Vector();
    for ( int i = 0; i < size; i++ ) {
    itemsVec.addElement ( model.getElementAt ( i ) );
    return itemsVec;
    return null;
    //===================================================================================
    class ComboMouseListener extends MouseAdapter {
    public void mouseClicked ( MouseEvent me ) {
    ButtonsCombo.this.hidePopup ();
    public void mousePressed ( MouseEvent me ) {
    ButtonsCombo.this.hidePopup ();
    ButtonsCombo.this.setBorder ( BorderFactory.createBevelBorder ( BevelBorder.LOWERED ) );
    public void mouseReleased ( MouseEvent me ) {
    ButtonsCombo.this.hidePopup ();
    ButtonsCombo.this.setBorder ( BorderFactory.createBevelBorder ( BevelBorder.RAISED ) );
    //===================================================================================
    class ComboRenderer extends JLabel implements ListCellRenderer {
    //````````````````````````````````````````````````
    public ComboRenderer () {
    setOpaque ( true );
    //````````````````````````````````````````````````
    public Component getListCellRendererComponent ( JList list, Object value, int index, boolean isSelected, boolean cellHasFocus ) {
    setBackground ( isSelected ? Color.cyan : Color.white );
    setForeground ( isSelected ? Color.red : Color.black );
    setText ( ( String )value );
    return this;
    //````````````````````````````````````````````````
    //===================================================================================
    // We have to use this class, otherwise we cannot stop JComboBox's popup to go down
    class ComboUI extends BasicComboBoxUI {
    public JButton createArrowButton () throws NullPointerException {
    try {
    URL url = getClass ().getResource ( "/images/comboarrow.gif" );
    JButton b = new JButton( new ImageIcon( url ) );
    b.addActionListener ( new ActionListener() {
    public void actionPerformed ( ActionEvent ae ) {
    return b;
    } catch ( NullPointerException npe ) {
    throw new NullPointerException( "/images/comboarrow.gif not found or /images folder not in classpath" );
    catch ( Exception e ) {
    e.printStackTrace ();
    return null;
    //======================================================================
    you can cutomize this according to your requirement , okie ;)

  • How to add a button with Javascript to Library

    Hi
    I am using Captivate 5.5 to create a template.
    In the files which will be created using this template, we will be adding a button which executes a Javascript. Now, my question is, since this button will be used on multiple slides in the file, can I add this button (with the Javascript) to the library? Currently, we create it manually everytime.
    We don't have a programmer in our team, so we can't create widget. Is there an alternative way?
    Thanks for your help.
    Sreekanth

    Thanks for that reply.
    I now have a blank slide with the button (including the javascript) on it which solves the problem of importing it manually.
    However, when we use this template to import PowerPoint presentations, when we publish the file, the first slide (the one on which I have this button) will be blank and has to be manually deleted.
    Is there a way to eliminate this manual work? I tried hiding and using some actions. But it was not of any use.

  • How to create a button with an attached menu?

    I don't know how these buttons are called but I'll try to explain what I want to do. I have a toolbar where I have a button that cycles through several functions on every action - I use it to cycle through display modes. Because I do not want to switch through all other posibilties I want a menu next to it where I can directly switch to the desired display mode. Clicking on the button cycles through the modes and clicking on the attached menu provides a direct selection. What I have in mind is something like the "show images / show no images / show cached images only" Button in the Opera webbrowser, see
    http://img32.imagevenue.com/img.php?loc=loc74&#8465;=a33_button_menu.jpg
    Currently I'm using a group of JToggleButtons but since I'm going to add new display modes adding new buttons would make the toolbar look too crowded.

    See if this is useful
    import javax.swing.*;
    import java.awt.event.*;
    import java.awt.*;
    class SwingA implements ActionListener
    JPopupMenu pop;
    JFrame frame;
    JPanel panel;
    JButton cmdPop;
    JDialog dlgFrame;
    int times_clicked = 0;
         public static void main(String[] args)
         SwingA A=new SwingA();
         SwingA()
                    try
              UIManager.setLookAndFeel("com.sun.java.swing.plaf.windows.WindowsLookAndFeel");
                      frame=new JFrame("PopUp");
                      frame.setSize(600,480);
                      frame.setExtendedState(JFrame.MAXIMIZED_BOTH);
                      pop=new JPopupMenu();
                      cmdPop=new JButton("Click");
                     cmdPop.addActionListener(this);
                   JMenuItem item = new JMenuItem("First");
                   JMenuItem item1 = new JMenuItem("Second");
                   pop.add(item);
                   pop.add(item1);
                     panel=new JPanel();
                      panel.add(cmdPop);
                      frame.getContentPane().add(panel);
                      frame.setVisible(true);
              catch(Exception E)
         public void actionPerformed(ActionEvent source)
           pop.show(cmdPop, cmdPop.getWidth(), 0);
    }

  • How can i create a button with a dynamic picture?

    How can i create a button with a dynamic picture using
    mcLoader.loadClip
    I did create one with it doesnt seem to be working. It loses
    all its
    functions (eg onPress onRelease)
    Thanks

    I solved thep roblem anyway creating a mc.. then creating
    another MC withing
    the first MC and i change the picture on the second MC. And i
    apply the
    propierities to the first MC , and works
    If i have troubles with mu sistem on the future I will use
    yours!
    Thanks!
    "the fleece" <[email protected]>
    escribi� en el mensaje
    news:e67i88$jlf$[email protected]..
    > the image loading will remove any properties or
    functions the mc had.
    >
    > you need to apply them in the onLoadInit function
    >
    > mclListener.onLoadInit = function(target_mc:MovieClip) {
    > target_mc.onRollOver=blah blah
    > };
    > var image_mcl:MovieClipLoader = new MovieClipLoader();
    > image_mcl.addListener(mclListener);
    > image_mcl.loadClip(blah, blahblah);
    >
    >

  • Help!!! How to create simple menu with buttons.

    I basically need help on how to create a menu with Up, Left, Next and Back buttons.
    Then it must have a submenus like Telephone, Lights, Fans and Television.
    and more sub sub menus of On and Off buttons.
    Ive jut started to learn Labview and a newbie at it.
    It could be really nice if someone could make an example.
    Would appreciate it if it could work like Ipod interface.
    Thanksssss! Pls help!

    Duplicate post.

  • How to create a complaint with pre-decessor document Inovice?

    Hello experts,
    I need create a complaint with reference to a pre-decessor document type Invoice (apart from other types such as sales order and service order). Can someone enlighten me
    1) how to create an invoice in IC Web Client and backend?
    2) how to create a complaint with reference to this created invoice in IC Web client and backend?
    Thanks a lot!!!

    Hi Easwar
    Thanks  a lot for answering the question.
    Yes I do have CRM Billing documents. But the problem is
    a) either the billing document doesn't have Transfer to Accounting status Transferred or
    b) a transferred billing document, but all items have error "Unable to offset billing item 90003458 0000000060" etc.
    Do you know
    1) how I can make a billing document have "Transferred" status? Pressing "Transfer to Accounting" button in the billing document overview page will only set the status to "Being transferred". And it's always being tranfered.
    2) What does the error "Unable to offset billing item ... "mean? How to get rid of them?
    Thanks a lot!

  • How to create SAVE button in Workbook using BI IP Functionality

    Hi All,
    I have Real-time Infocube (ZCUBSDID) with me. Planning has been done on the cube using BI-IP (like Aggregation level, filter, planning function and planning sequence are present there).
    As an Input i have everything in Quality system like I can access query in Bex Anlyzer (Input Ready Query) and also i have workbook associated with the query. SAVE button is also present on workbook which is giving result based on fiscal year and version.
    Now my task is to create workbook on Development system with the same functionality as Quality System.
    I have same Query available on DEV system also. I created new  Workbook but SAVE button is not available in my workbook.
    Can anyone suggest how to create SAVE button in my new workbook.
    I am new in IP side so please let me know if i can get any help from workbook which is already present in Quality system.
    Which type of analysis i should do to come out with solution.....otherwise let me know step by step procedure to create SAVE button on workbook using BI-IP functionality.
    It will be great help. My advance thanks goes to you people.
    Thanks,
    Rupali Singh

    Check points 19 & 20 on this link http://help.sap.com/saphelp_nw2004s/helpdata/en/43/a033e0f56e21b5e10000000a1553f6/frameset.htm.
    Command to be called on SAVE button is SAVE_AREA as explained in the point 20.
    Regards,
    Deepti

  • How to create a field with  1200 chars length

    Hi,
    Will anybody let me know how to create a field with length 1200 in a table.
    Regards,
    Madhavi

    Hi Madhvi,
    Other thing what you can do is
    1. First create a Table type.
         Goto SE11-> Dataelements ->Table type
         There on the next screen select Predefine radio button & there provide data type & size.
    2. Create a structure having a field typa of Table type created before. say that field is quant.
    Now in your program refer that structure to create an internal table & work area.
    Now if u append ur text to the field quant.
    try creating line type of size more that 255 if it works then fine other wise reduce it.
    Note:: This will be a deep structure.
    so first append value to the field quant,  the at the end of first record append valu to ur internal table.
    thanks
    Satyam

  • How to create a window with its own window border other than the local system window border?

    How to create a window with its own window border other than the local system window border?
    For example, a border: a black line with a width 1 and then a transparent line with a width 5. Further inner, it is the content pane.
    In JavaSE, there seems to have the paintComponent() method for the JFrame to realize the effect.

    Not sure why your code is doing that. I usually use an ObjectProperty<Point2D> to hold the initial coordinates of the mouse press, and set it to null on a mouse release. That seems to avoid the dragging being confused by mouse interaction with other nodes.
    import javafx.application.Application;
    import javafx.application.Platform;
    import javafx.beans.property.ObjectProperty;
    import javafx.beans.property.SimpleObjectProperty;
    import javafx.collections.FXCollections;
    import javafx.event.ActionEvent;
    import javafx.event.EventHandler;
    import javafx.geometry.Point2D;
    import javafx.geometry.Pos;
    import javafx.scene.Node;
    import javafx.scene.Scene;
    import javafx.scene.control.Button;
    import javafx.scene.control.ChoiceBox;
    import javafx.scene.input.MouseEvent;
    import javafx.scene.layout.AnchorPane;
    import javafx.scene.layout.StackPane;
    import javafx.scene.layout.VBox;
    import javafx.scene.paint.Color;
    import javafx.stage.Stage;
    import javafx.stage.StageStyle;
    import javafx.stage.Window;
    public class CustomBorderExample extends Application {
      @Override
      public void start(Stage primaryStage) {
      AnchorPane root = new AnchorPane();
      root.setStyle("-fx-border-color: black; -fx-border-width: 1px; ");
      enableDragging(root);
      StackPane mainContainer = new StackPane();
        AnchorPane.setTopAnchor(mainContainer, 5.0);
        AnchorPane.setLeftAnchor(mainContainer, 5.0);
        AnchorPane.setRightAnchor(mainContainer, 5.0);
        AnchorPane.setBottomAnchor(mainContainer, 5.0);
      mainContainer.setStyle("-fx-background-color: aliceblue;");
      root.getChildren().add(mainContainer);
      primaryStage.initStyle(StageStyle.TRANSPARENT);
      final ChoiceBox<String> choiceBox = new ChoiceBox<>(FXCollections.observableArrayList("Item 1", "Item 2", "Item 3"));
      final Button closeButton = new Button("Close");
      VBox vbox = new VBox(10);
      vbox.setAlignment(Pos.CENTER);
      vbox.getChildren().addAll(choiceBox, closeButton);
      mainContainer.getChildren().add(vbox);
        closeButton.setOnAction(new EventHandler<ActionEvent>() {
          @Override
          public void handle(ActionEvent event) {
            Platform.exit();
      primaryStage.setScene(new Scene(root,  300, 200, Color.TRANSPARENT));
      primaryStage.show();
      private void enableDragging(final Node n) {
       final ObjectProperty<Point2D> mouseAnchor = new SimpleObjectProperty<>(null);
       n.addEventHandler(MouseEvent.MOUSE_PRESSED, new EventHandler<MouseEvent>() {
          @Override
          public void handle(MouseEvent event) {
            mouseAnchor.set(new Point2D(event.getX(), event.getY()));
       n.addEventHandler(MouseEvent.MOUSE_RELEASED, new EventHandler<MouseEvent>() {
          @Override
          public void handle(MouseEvent event) {
            mouseAnchor.set(null);
       n.addEventHandler(MouseEvent.MOUSE_DRAGGED, new EventHandler<MouseEvent>() {
          @Override
          public void handle(MouseEvent event) {
            Point2D anchor = mouseAnchor.get();
            Scene scene = n.getScene();
            Window window = null ;
            if (scene != null) {
              window = scene.getWindow();
            if (anchor != null && window != null) {
              double deltaX = event.getX()-anchor.getX();
              double deltaY = event.getY()-anchor.getY();
              window.setX(window.getX()+deltaX);
              window.setY(window.getY()+deltaY);
      public static void main(String[] args) {
      launch(args);

  • Can someone tell me how to create accounting entries with the account status as error

    Hi,
    Can someone tell me how to create accounting entries with the
    account status as error?
    Thanks!!
    Danny

    It's call fixed/static background, and it is NOT directly support by iweb, you will need post processing either in html or javascript.
    Varkgirl (you need to search the previous forum) and I did it since iweb1:
    try Safari, and scroll: http://www.geocities.com/[email protected]/Links.html
    invisible link? roddy, fishing for info again?

  • How to create a button icon list similar to Timesheet application

    Hi,
    Can someone tell me how to create an icon, with drop down list that looks and work similar to the button we can find in the Timesheet application in the URL below: http://apex.oracle.com/pls/otn/f?p=35222:LOGIN
    Thanks!

    Hi,
    Click your list region
    click the name of the list
    it will redirects to list property
    choose the name of the specific list item it will open for attribute setting
    choose image right side small button will pop up the existing images or
    upload your image [shared components] access #APP_IMAGES#image1.gif
    Thanks,
    Loga

  • Button with Javascript appearance changed.

    Hi,
    I created button with javascript from
    Re: Button and Function
    Everything works fine, But button looks different now
    No appearance of button is there & button label is displayed in orange color.
    Have i missed something or i will never like original.

    I have done some changes suggested by ATD for another thread.
    In your app, through Shared Components, Templates create a new button template based on a copy of an existing one (pick whichever existing template you prefer, the normal Button may be ok). When the new template is created, edit it. You should see something like the following in the "Template" setting:
    a href="#LINK#" class="t12Button" #BUTTON_ATTRIBUTES#>#LABEL#</a
    There may be other HTML around this, but this is the important part as it is the actual button itself. Change this to:
    a href="#" class="t12Button" #BUTTON_ATTRIBUTES#>#LABEL#</a
    Now, on your button on the page, change it to use your new button template. In the Button Attributes setting, add in:
    onclick="javascript:checkText();"
    everything works fine except appearance of button.
    Edited by: TEJU on Jun 4, 2009 10:21 AM
    Edited by: TEJU on Jun 4, 2009 10:22 AM
    Edited by: TEJU on Jun 4, 2009 10:24 AM

  • How to create radio button between two slection screen

    hello all.
    could you please guide me how to create radio button between two SELECTION-SCREEN  in screen painter.
    Thank you,
    srinivas

    hi
    SEE THIS CODE
    REPORT  ZNNR_REPORT NO STANDARD PAGE HEADING MESSAGE-ID ZNNR LINE-SIZE 100 LINE-COUNT 65(4).
    ******DATA DECLARATIONS**********
    DATA : BEGIN OF IT_PLANT OCCURS 0,
            MATNR LIKE MARA-MATNR,
            WERKS LIKE MARC-WERKS,
            PSTAT LIKE MARC-PSTAT,
            EKGRP LIKE MARC-EKGRP,
           END OF IT_PLANT.
    DATA : BEGIN OF IT_PONO OCCURS 0,
            EBELN LIKE EKKO-EBELN,
            EBELP LIKE EKPO-EBELP,
            MATNR LIKE EKPO-MATNR,
            WERKS LIKE EKPO-WERKS,
            LGORT LIKE EKPO-LGORT,
           END OF IT_PONO.
    TABLES EKKO.
    ********END OF DATA DECLARATIONS*********
    ********SELECTION SCREEN DESIGN ***********
    SELECTION-SCREEN BEGIN OF BLOCK B1 WITH FRAME TITLE TEXT-001.
    PARAMETER : P_WERKS LIKE MARC-WERKS MODIF ID S1.
    SELECT-OPTIONS : S_EBELN FOR EKKO-EBELN NO INTERVALS MODIF ID S2.
    SELECTION-SCREEN END OF BLOCK B1.
    SELECTION-SCREEN BEGIN OF LINE.
    PARAMETERS : R3 RADIOBUTTON GROUP G2 DEFAULT 'X'.
    SELECTION-SCREEN COMMENT 5(20) TEXT-003 FOR FIELD R3.
    SELECTION-SCREEN END OF LINE.
    SELECTION-SCREEN BEGIN OF LINE.
    PARAMETERS : R4 RADIOBUTTON GROUP G2.
    SELECTION-SCREEN COMMENT 5(20) TEXT-004 FOR FIELD R4.
    SELECTION-SCREEN END OF LINE.
    SELECTION-SCREEN BEGIN OF BLOCK B2 WITH FRAME TITLE TEXT-004.
    SELECTION-SCREEN BEGIN OF LINE.
    PARAMETERS : R1 RADIOBUTTON GROUP G1 DEFAULT 'X'.
    SELECTION-SCREEN COMMENT 5(20) TEXT-002 FOR FIELD R1.
    SELECTION-SCREEN END OF LINE.
    SELECTION-SCREEN BEGIN OF LINE.
    PARAMETERS : R2 RADIOBUTTON GROUP G1.
    SELECTION-SCREEN COMMENT 5(20) TEXT-003 FOR FIELD R2.
    SELECTION-SCREEN END OF LINE.
    SELECTION-SCREEN END OF BLOCK B2.
    ******END OF SELECTION SCREEN DESIGN****************
    <b>rEWARD IF USEFULL</b>

  • How to create a node with attributes at runtime in webdynpro for ABAP?

    Hi Experts,
             How to create a node with attributes at runtime in webdynpro for ABAP? What classes or interfaces I should use? Please provide some sample code.
    I have checked IF_WD_CONTEXT_NODE_INFO and there is ADD_NEW_CHILD_NODE method. But this is not creating any node. I this this creates only a "node info" object.
    I even check IF_WD_CONTEXT_NODE but i could not find any method that creates a node with attribute.
    Please help!
    Thanks
    Gopal

    Hi
       I am getting the following error while creating a dynamic context node with 2 attributes. Please help me resolve this problem.
    Note
    The following error text was processed in the system PET : Line types of an internal table and a work area not compatible.
    The error occurred on the application server FMSAP995_PET_02 and in the work process 0 .
    The termination type was: RABAX_STATE
    The ABAP call stack was:
    Method: IF_WD_CONTEXT_NODE~GET_STATIC_ATTRIBUTES_TABLE of program CL_WDR_CONTEXT_NODE_VAL=======CP
    Method: GET_REF_TO_TABLE of program CL_SALV_WD_DATA_TABLE=========CP
    Method: EXECUTE of program CL_SALV_WD_SERVICE_MANAGER====CP
    Method: APPLY_SERVICES of program CL_SALV_BS_RESULT_DATA_TABLE==CP
    Method: REFRESH of program CL_SALV_BS_RESULT_DATA_TABLE==CP
    Method: IF_SALV_WD_COMP_TABLE_DATA~MAP_FROM_SOURCE_DATA of program CL_SALV_WD_C_TABLE_V_TABLE====CP
    Method: IF_SALV_WD_COMP_TABLE_DATA~MAP_FROM_SOURCE of program CL_SALV_WD_C_TABLE_V_TABLE====CP
    Method: IF_SALV_WD_COMP_TABLE_DATA~UPDATE of program CL_SALV_WD_C_TABLE_V_TABLE====CP
    Method: IF_SALV_WD_VIEW~MODIFY of program CL_SALV_WD_C_TABLE_V_TABLE====CP
    Method: IF_SALV_WD_COMPONENT~VIEW_MODIFY of program CL_SALV_WD_A_COMPONENT========CP
    My code is like the following:
    TYPES: BEGIN OF t_type,
                CARRID TYPE sflight-carrid,
                CONNID TYPE sflight-connid,
             END OF t_type.
      Data:  i_struc type table of t_type,
      dyn_node   type ref to if_wd_context_node,
      rootnode_info   type ref to if_wd_context_node_info,
      i_node_att type wdr_context_attr_info_map,
      wa_node_att type line of wdr_context_attr_info_map.
          wa_node_att-name = 'CARRID'.
          wa_node_att-TYPE_NAME = 'SFLIGHT-CARRID'.
          insert wa_node_att into table i_node_att.
          wa_node_att-name = 'CONNID'.
          wa_node_att-TYPE_NAME = 'SFLIGHT-CONNID'.
          insert wa_node_att into table i_node_att.
    clear i_struc. refresh i_struc.
      select carrid connid into corresponding fields of table i_struc from sflight where carrid = 'AA'.
    rootnode_info = wd_context->get_node_info( ).
    rootnode_info->add_new_child_node( name = 'DYNFLIGHT'
                                       attributes = i_node_att
                                       is_multiple = abap_true ).
    dyn_node = wd_context->get_child_node( 'DYNFLIGHT' ).
    dyn_node->bind_table( i_struc ).
    l_ref_interfacecontroller->set_data( dyn_node ).
    I am trying to create a new node. That is
    CONTEXT
    - DYNFLIGHT
    CARRID
    CONNID
    As you see above I am trying to create 'DYNFLIGHT' along with the 2 attributes which are inside this node. The structure of the node that is, no.of attributes may vary based on some condition. Thats why I am trying to create a node dynamically.
    Also I cannot define the structure in the ABAP dictionary because it changes based on condition
    Message was edited by: gopalkrishna baliga

Maybe you are looking for