display:table.... /display:table   export problem

HI,
when I wrote in the jsp:
<display:table pagesize="30" class="isis" name="contacts" export="true">
<display:column property="firstName"/>
<display:column property="lastName"/>
<display:column property="title"/>
<display:column property="gender"/>
<display:column property="phoneNumber"/>
<display:column property="email"/>
<display:column property="country.phonePrefix" title="Country"/>
<display:column property="birthdate"/>
</display:table>
There are Export | CSV | EXCL |xmL for users to export the table.
But when I click the CSV, there are nothing to do,
How can I do that?
thanks,

Hi jcatino ,
Thank you very much.
But I also have another problem:
<display:table pagesize="20" class="isis" name="subscribers" id="subscriber" export="true" requestURI="manageContact.do">
<display:column sortable="true" >
<c:out value="${subscriber.UID}"/>
</display:column>
          <logic:iterate id="group" name="groups" indexId="index2">
               <logic:iterate id="extendedProfile" name="subscriber" property="extendedProfiles">
               <logic:equal name="extendedProfile" property="source.id" value="${group.id}">
                    <display:column title="${group.name}">${extendedProfile.actualValue}</display:column>
               </logic:equal>
          </logic:iterate>
          </logic:iterate>
     </display:table>
The result that I got from clicking the "CSV" is that:
"<a href=\"manageContact.do?contactId=10&task=do_edit\">
10
</a>",VW Jetta owners,2005-3-2 00:00:00.000000000,aa,2233,2006-10-30 00:00:00.000000000,[email protected],12345
"<a href=\"manageContact.do?contactId=11&task=do_edit\">
11
</a>",VW Jetta owners,2004-2-28 00:00:00.000000000,aa,aacc,2006-11-30 00:00:00.000000000,[email protected],12345
How can I delete the <a..............> </a> ?
I have read information from the website : http://displaytag.sourceforge.net/configuration.html
However, I have no idea to solve it?
thanks you
happybaobao

Similar Messages

  • Problem with Table display in Adobe Form of Web Dynpro ABAP

    Hi Team,
    I'm trying to display a table in Adobe Print Form (not interactive). The table is bound to the context node in the Web Dynpro ABAP where the cardinality is 0:N. I get a short dump. Don't know what to do here. I'm able to display individual fields from my context successfully. Looks like something is missing when I try to display a table. Any pointers to display a data table in Adobe? Any step by step example you know of where I can find out what I did wrong? Many thanks for your time
    We are on support pack SP06 on 2004S release.
    DUMP INFORMATION:
    Short text                                                               
        Access via 'NULL' object reference not possible.                 
    What happened?                                                           
        Error in the ABAP Application Program  The current ABAP program "CL_WD_ADOBE_SERVICES==========CP" had to be terminated because it has come across a statement that unfortunately cannot be executed.
    An exception occurred that is explained in detail below.                    
    The exception, which is assigned to class 'CX_SY_REF_IS_INITIAL', was not caught in procedure "CREATE_PDF" "(METHOD)", nor was it propagated by a RAISING clause.

    Hi Thomas,
    We upgraded our system(2004S) to SP10 so that we can use the ADOBE form printing in Web Dynpro ABAP but could not apply note 1034425 because of the validity constraints in SNOTE. All the pre-requisite notes are already in the system apart from one note 1029721 which talks about supporting input helps. We don't want to use input helps in our system and cannot upgrade to SP11 because of problems with Business functionality.
    Questions:
    1) Is note 1034425 absolutely dependent on 1029721?
    2) If NOT, can someone please correct the validity so that we can implement using SNOTE.
    3) Would it be OK if we manually apply the changes specified in 1034425 without implementing 1029721?
    4) If all of the above is not applicable, is there any other note which fixes the above mentioned short dump.
    Your help in this matter will greatly help us in using the ADOBE services provided by SAP WDA.
    Thanks much

  • Problem In Displaying records in table

    Hi,
    I have created a table and set the records displayed property as 10.But in controller I am dynamically inserting one row in the table at index 0.
    So whenever the vo returns morethan 10 rows ,the table displays last record first.Suppose the vo returns 11 records,then in the page I am able to see
    only the last record i.e 11th record,then i have to navigate in the table to see the first 10 records.My requirement is I want to see the 10 records first.PLs help me.

    The following code is written in co process request.
    OAViewObject oaviewobject = (OAViewObject)am.findViewObject("XXCHRCwkMatchingPersonVO1");
    oaviewobject.setWhereClauseParam(0,first_name);
    oaviewobject.setWhereClauseParam(1,last_name);
    oaviewobject.setWhereClauseParam(2,dtStartDate);
    oaviewobject.executeQuery();
    pageContext.getApplicationModule(webBean).invokeMethod("checkCwkDuplicates");
    -------------AM method
    public void checkCwkDuplicates()
    PerOAViewObjectImpl peroaviewobjectimpl = getXXCHRCwkMatchingPersonVO1();
    OARow oarow = (OARow)peroaviewobjectimpl.createRow();
    Number n=new Number(0);
    String s35 = getOADBTransaction().getMessage("PER", "PER_289352_DUP_PER_NO_MATCH", null);
    oarow.setAttribute("FullName", s35);
    oarow.setAttribute("Mondiff", n);
    oarow.setAttribute("Switcher", "Enable");
    peroaviewobjectimpl.insertRowAtRangeIndex(0, oarow);
    pls help me.

  • Problem while displaying all the table names from a MS Access Data Source.

    I started preparing a small Database application. I want to display all the Table Names which are in the 'MS Access' Data Source.
    I started to executing by "Select * from Tab" as if in SQL.
    But i got an error saying that "Not able to resolve Symbol 'Tab' in the query".
    Please let me know how can i display all the table Names in the MS Access Dats Source.

    Here i am developing the application in Swing using JDBC for accessing the database.
    I want to display all the Table names from the data source in a ListBox for easy selection of tables to view their details.

  • Data not displayed in Z-table when material code (MATNR) entered in selection screen.

    Hi Experts,
    I have a Z-table for a gatepass report which was already created by another developer. This table has many fields including plant, year, material code field. (MATNR) etc
    Now the problem is in SE11, I run the table to display the entries, when I enter plant and year and execute many entries are displayed.properly including material codes(e.g.50008536). 
    But when I execute the same entering plant, year and material code(e.g.50008536) then this message is displayed. " No table entries found for specified key"
    The same thing happens if I am writing a select query in my report to get the data of any particular material code. My internal table is not filled with the data including that particular material code.
    Some more info :
    1. The material code field in the Z-table is assigned the standard material code Data element. i.e. MATNR
    2. Even if I enter '000000000050008536' as input it is still not working. it is automatically changed to '50008536' after executing.
    So please help me where the problem is? I have spent alot of time on this but not able to find the problem..
    Thanks,
    Vishal .

    Hi Vishal,
    Hope I understand  that table content does not starts with zero for material, reply me if i am wrong.
    Use this code before where condition.
    loop at so_matnr.
    CALL FUNCTION 'CONVERSION_EXIT_ALPHA_OUTPUT'
       EXPORTING
         INPUT         = so_matnr-low
      IMPORTING
        OUTPUT        = so_matnr-low.
    if so_matnr-high is NOT INITIAL.
    CALL FUNCTION 'CONVERSION_EXIT_ALPHA_OUTPUT'
       EXPORTING
         INPUT         = so_matnr-high
      IMPORTING
        OUTPUT        = so_matnr-high.
    endif.
    MODIFY  so_matnr.
    endloop.
    if table content is filled with zero use  FM conversion_exit_alpha_input
    Regards,
    Venkat.

  • How can i  change the column label text in a alv table display

    how can i change the column label text in a alv table display??
    A similar kinda of question was posted previuosly where the requirement was the label text was needed and following below code was given as solution :
    <i>*  declare column, settings, header object
    DATA: lr_column TYPE REF TO cl_salv_wd_column.
    DATA: lr_column_settings TYPE REF TO if_salv_wd_column_settings.
    DATA: lr_column_header type ref to CL_SALV_WD_COLUMN_HEADER.
    get column by specifying column name.
    lr_column = lr_column_settings->get_column( 'COLUMN_NAME1' ).
    set Header Text as null
    lr_column_header = lr_column->get_header( ).
    lr_column_header->set_text( ' ' ).</i>
    My specific requirement is i have an input field on the screen and i want reflect that value as the column label for one of the column in the alv table. I have used he above code with slight modification in the MODIFYVIEW method of the view since it is a process after input. The component gets activated without any errors but while run time i get an error stating
    <i>"The following error text was processed in the system CDV : Access via 'NULL' object reference not possible."</i>
    i have checked in debugging and the error occured at the statement :
    <i>lr_column = lr_column_settings->get_column( 'CURRENT_YEAR' ).</i>Please can you provide me an alternative for my requirement or correct me if i have done it wrong.
    Thanks,
    Suri

    I found it myself how to do it. The error says that it is not able to find the reference object i.e  it is asking us to refer to the table. The following piece of code will solve this problem. Have to implement this in WDDOMODIFYVIEW method of the view. This thing works comrades enjoy...
      DATA : lr_cmp_usage TYPE REF TO if_wd_component_usage,
             lr_if_controller  TYPE REF TO iwci_salv_wd_table,
             lr_cmdl   TYPE REF TO cl_salv_wd_config_table,
             lr_col    TYPE REF TO cl_salv_wd_column.
      DATA : node_year  TYPE REF TO if_wd_context_node,
             elem_year  TYPE REF TO if_wd_context_element,
             stru_year  TYPE if_alv_layout=>element_importing,
             item_year  LIKE stru_year-i_current_year,
             lf_string    TYPE char(x),
      DATA: lr_column TYPE REF TO cl_salv_wd_column.
      DATA: lr_column_header TYPE REF TO cl_salv_wd_column_header.
      DATA: lr_column_settings TYPE REF TO if_salv_wd_column_settings.
    Get the entered value from the input field of the screen
    node_year  = wd_context->get_child_node( name = 'IMPORTING_NODE' ).
    elem_year  = node_year->get_element( ).
      elem_year->get_attribute(
       EXPORTING
        name = 'IMPORT_NODE-PARAMETER'
       IMPORTING
        value = L_IMPORT_PARAM ).
      WRITE L_IMPORT_PARAM TO lf_string.
    Get the reference of the table
      lr_cmp_usage  =  wd_this->wd_cpuse_alv( ).
      IF lr_cmp_usage->has_active_component( ) IS INITIAL.
        lr_cmp_usage->create_component( ).
      ENDIF.
      lr_if_controller  = wd_this->wd_cpifc_alv( ).
      lr_column_settings = lr_if_controller->get_model( ).
    get column by specifying column name.
      IF lr_column_settings IS BOUND.
        lr_column = lr_column_settings->get_column( 'COLUMN_NAME').
    set Header Text as null
        lr_column_header = lr_column->get_header( ).
        lr_column_header->set_text( lf_string ).
    endif.

  • Column to row display of internal table values

    Hi guys,
    I have the internal table in the following manner
    MATNR     ADSIZE     PRICE
    220p     15m     100
    220p     16m     120
    220p     17m     230
    230p     16m     200
    230p     17m     120
    230p     18m     220
    240p     17m     120
    250p     18m     560
    And want to change to the below mentioned manner, please note that there can be multiple matnr's and multiple adsizes as well.
    MATNR     15m     16m     17m     18m     ......(dynamic:depends on                                                                               
    user )
    220p     100     120     230
    230p     -     200     120     220...and so on.
    How do i display in the above manner.
    Please help.
    Thanks in advance.
    Regards,
    Santosh Kotra.

    Hi Santosh.
    I work hard in this topic. I will post my solution, try to adequate to your needs.
    If your problem is solved, talk to me about your solution.
    I create 2 dynamics tables to do this. I create a it to save the column position to populate the table for alv.
    Change the select (form select) to see with others filters.
    I hope this help you and others.
    Regards
    *& Report  ZDYNAMIC                                                    *
    REPORT  zdynamic                                .
    Tables
    DATA: lt_data TYPE REF TO data,
          lt_new  TYPE REF TO data.
    DATA: lt_fieldcatalog TYPE lvc_t_fcat.
    Structure
    DATA: ls_fieldcatalog TYPE lvc_s_fcat,
          BEGIN OF mat OCCURS 0,
            name TYPE string,
            pos TYPE i,
          END OF mat.
    Data References
    DATA: new_line TYPE REF TO data,
          tab_line TYPE REF TO data.
    Field Symbols
    FIELD-SYMBOLS: <fs_data> TYPE REF TO data,
                   <fs_data1> TYPE REF TO data,
                   <fs_1> TYPE STANDARD TABLE,
                   <ntab> TYPE STANDARD TABLE,
                   <fs_2>,
                   <tab2>,
                   <fs_3>,
                   <tab3>.
    Vars
    DATA: index LIKE sy-index.
    PERFORM fieldcat.
    ASSIGN lt_data TO <fs_data>.
    ASSIGN lt_new  TO <fs_data1>.
    PERFORM cria_tab USING lt_fieldcatalog 1.
    ASSIGN <fs_data>->* TO <fs_1>.
    CREATE DATA new_line LIKE LINE OF <fs_1>.
    ASSIGN new_line->*  TO <fs_2>.
    And to put the data in the internal table
    PERFORM select.
    preencher fieldcat tabela nova
    CLEAR lt_fieldcatalog[].
    LOOP AT <fs_1> ASSIGNING <fs_2>.
      DO.
        ASSIGN COMPONENT sy-index OF STRUCTURE <fs_2> TO <fs_3>.
        IF sy-subrc <> 0.
          EXIT.
        ENDIF.
        IF sy-index = 1.
          CLEAR ls_fieldcatalog.
          ls_fieldcatalog-coltext   = 'CARRID'.
          ls_fieldcatalog-fieldname = 'CARRID'.
          ls_fieldcatalog-inttype = 'C'.
          APPEND ls_fieldcatalog TO lt_fieldcatalog.
        ENDIF.
        IF sy-index = 2.
          CLEAR ls_fieldcatalog.
          ls_fieldcatalog-coltext   = <fs_3>.
          ls_fieldcatalog-fieldname = <fs_3>.
          ls_fieldcatalog-inttype = 'C'.
          APPEND ls_fieldcatalog TO lt_fieldcatalog.
        ENDIF.
      ENDDO.
    ENDLOOP.
    SORT lt_fieldcatalog DESCENDING BY fieldname.
    DELETE ADJACENT DUPLICATES FROM lt_fieldcatalog.
    LOOP AT lt_fieldcatalog INTO ls_fieldcatalog.
      mat-name = ls_fieldcatalog-coltext.
      mat-pos  = sy-tabix.
      APPEND mat.
    ENDLOOP.
    *create new table
    PERFORM cria_tab USING lt_fieldcatalog 2.
    add data
    ASSIGN <fs_data1>->* TO <ntab>.
    CREATE DATA tab_line LIKE LINE OF <ntab>.
    ASSIGN tab_line->*  TO <tab2>.
    LOOP AT <fs_1> ASSIGNING <fs_2>.
      DO.
        ASSIGN COMPONENT sy-index OF STRUCTURE <fs_2> TO <fs_3>.
        IF sy-subrc <> 0.
          EXIT.
        ENDIF.
        IF sy-index = 1.
          ASSIGN COMPONENT sy-index OF STRUCTURE <tab2> TO <tab3>.
          <tab3> = <fs_3>.
        ELSEIF sy-index = 3.
          ASSIGN COMPONENT 2 OF STRUCTURE <fs_2> TO <fs_3>.
          READ TABLE mat WITH KEY name = <fs_3>.
          index = mat-pos.
          ASSIGN COMPONENT sy-index OF STRUCTURE <fs_2> TO <fs_3>.
          ASSIGN COMPONENT index OF STRUCTURE <tab2> TO <tab3>.
          <tab3> = <fs_3>.
        ENDIF.
      ENDDO.
      APPEND <tab2> TO <ntab>.
      CLEAR <tab2>.
    ENDLOOP.
    PERFORM display.
    FORM display
    FORM display.
      CALL FUNCTION 'REUSE_ALV_GRID_DISPLAY_LVC'
        EXPORTING
          it_fieldcat_lvc = lt_fieldcatalog
        TABLES
         t_outtab        = <fs_1>
          t_outtab        = <ntab>
        EXCEPTIONS
          program_error   = 1
          OTHERS          = 2.
      IF sy-subrc <> 0.
        MESSAGE ID sy-msgid TYPE sy-msgty NUMBER sy-msgno
                WITH sy-msgv1 sy-msgv2 sy-msgv3 sy-msgv4.
      ENDIF.
    ENDFORM.                    "display
    FORM fieldcat
    FORM fieldcat.
      CLEAR ls_fieldcatalog.
      ls_fieldcatalog-coltext   = 'CARRID'.
      ls_fieldcatalog-fieldname = 'CARRID'. "Fieldname
      ls_fieldcatalog-inttype = 'C'. "Internal Type C-> Character
      APPEND ls_fieldcatalog TO lt_fieldcatalog.
      ls_fieldcatalog-coltext   = 'CONNID'.
      ls_fieldcatalog-fieldname = 'CONNID'.
      ls_fieldcatalog-inttype = 'N'.
      APPEND ls_fieldcatalog TO lt_fieldcatalog.
      ls_fieldcatalog-coltext   = 'FLDATE'.
      ls_fieldcatalog-fieldname = 'FLDATE'.
      ls_fieldcatalog-inttype = 'D'.
      APPEND ls_fieldcatalog TO lt_fieldcatalog.
      ls_fieldcatalog-coltext   = 'PRICE'.
      ls_fieldcatalog-fieldname = 'PRICE'.
      ls_fieldcatalog-inttype = 'P'.
      APPEND ls_fieldcatalog TO lt_fieldcatalog.
      ls_fieldcatalog-coltext   = 'CURRENCY'.
      ls_fieldcatalog-fieldname = 'CURRENCY'.
      ls_fieldcatalog-inttype = 'C'.
      APPEND ls_fieldcatalog TO lt_fieldcatalog.
    ENDFORM.                    "fieldcat
    FORM cria_tab
    FORM cria_tab USING catalog TYPE lvc_t_fcat qual TYPE i.
      IF qual = 1.
        CALL METHOD cl_alv_table_create=>create_dynamic_table
          EXPORTING
            it_fieldcatalog           = catalog
          IMPORTING
            ep_table                  = <fs_data>
          EXCEPTIONS
            generate_subpool_dir_full = 1
            OTHERS                    = 2.
      ELSE.
        CALL METHOD cl_alv_table_create=>create_dynamic_table
          EXPORTING
            it_fieldcatalog           = catalog
          IMPORTING
            ep_table                  = <fs_data1>
          EXCEPTIONS
            generate_subpool_dir_full = 1
            OTHERS                    = 2.
      ENDIF.
    ENDFORM.                    "cria_tab
    FORM select
    FORM select.
      SELECT mandt carrid connid fldate price currency
        FROM sflight
        INTO CORRESPONDING FIELDS OF TABLE <fs_1>
        WHERE "carrid = 'AA' AND
        fldate > '20080101'.
    ENDFORM.                    "select

  • Saving a file from a form to be display on a table

    Hi i'm having some problems trying to save the filled out on the form to be displayed on the table i don't know how i am going to go about it can you please help me thanks.
    Here is the code for the form.
    import javax.swing.*;
    import javax.swing.text.*;
    import java.awt.*;              //for layout managers and more
    import java.awt.event.*;        //for action events
    import java.net.URL;
    import java.text.ParseException;
    import java.io.File;
    import java.io.FileOutputStream;
    import java.io.IOException;
    import javax.swing.JComboBox;
    public class DD extends JPanel
                                 implements ActionListener {
        private String newline = "\n";
        protected static final String textFieldString = "Name"; 
        protected static final String textFieldString1 = "Start Time";
        protected static final String textFieldString2 = "End Time";
        protected static final String textFieldString3 = "Total Time(Minutes)";
        protected static final String ftfString = "Date";
        protected static final String buttonString = "JButton";
        JFormattedTextField startTime;
        JTextField totalTime;
        protected JLabel actionLabel;
        Component[][] rowData;
        private String[] shapeName = { "Meeting", "Lunch", "Holiday", "Sickness",
                 "Preparing report", "Administrative work", "Emails", "Query" };
        public DD() {
            setLayout(new BorderLayout());
            Panel data = new Panel();
              data.setLayout(new GridLayout(7, 4));
            rowData = new Component[7][];
    //      One row
                   for (int row = 0; row < 7; row++)
                        rowData[row] = new Component[5];
                        rowData[row][0] = new TextField(10);
                        rowData[row][1] = new TextField(10);
                        ((TextField) rowData[row][1]).addActionListener(this);
                        rowData[row][2] = new JComboBox(shapeName);
                        ((JComboBox) rowData[row][2]).addActionListener(this);
    //      ((TextField)rowData[ row ][ 2 ]).addActionListener(this);
                        rowData[row][3] = new TextField(10);
                        ((TextField) rowData[row][3]).addActionListener(this);
    //      JComboBox jcboxShapeCombo;
    //      System.out.println(rowData[row][2]);
    //      jcboxShapeCombo[2] = new JComboBox (shapeName);
    //      rowData[ row ][ 3 ] = new TextField(10);
                        rowData[row][4] = new TextField(10);
                        ((TextField) rowData[row][4]).addActionListener(this);
                        java.text.SimpleDateFormat sdf = new java.text.SimpleDateFormat("H:mm");
                        ((TextField) rowData[row][0]).setText(sdf.format(new java.util.Date()));
                        data.add(rowData[row][0]);
                        data.add(rowData[row][1]);
                        data.add(rowData[row][2]);
                        data.add(rowData[row][3]);
                        data.add(rowData[row][4]);
            //Create a regular text field.
            JTextField textField = new JTextField(10);
            textField.setActionCommand(textFieldString);
            textField.addActionListener(this);
            java.text.SimpleDateFormat sdf = new java.text.SimpleDateFormat("H:mm");
            startTime = new JFormattedTextField(sdf);
            startTime.setValue(new java.util.Date());
            startTime.setActionCommand(textFieldString1);
            startTime.addActionListener(this);
            JTextField textField2 = new JTextField(10);
            textField2.setActionCommand(textFieldString2);
            textField2.addActionListener(this);
            totalTime = new JTextField(10);
            totalTime.setActionCommand(textFieldString3);
            totalTime.addActionListener(this);
            //Create a formatted text field.
            JFormattedTextField ftf = new JFormattedTextField(
                      //java.text.SimpleDateFormat sdf = new java.text.SimpleDateFormat("H:mm");
                    java.util.Calendar.getInstance().getTime());
            ftf.setActionCommand(textFieldString);
            ftf.addActionListener(this);
            //Create some labels for the fields.
            JLabel textFieldLabel = new JLabel(textFieldString + ": ");
            textFieldLabel.setLabelFor(textField);
            JLabel textFieldLabel1 = new JLabel(textFieldString1 + ": ");
            textFieldLabel1.setLabelFor(startTime);
            JLabel textFieldLabel2 = new JLabel(textFieldString2 + ": ");
            textFieldLabel2.setLabelFor(textField2);
            JLabel textFieldLabel3 = new JLabel(textFieldString3 + ": ");
            textFieldLabel3.setLabelFor(totalTime);
            JLabel ftfLabel = new JLabel(ftfString + ": ");
            ftfLabel.setLabelFor(ftf);
            //Create a label to put messages during an action event.
            actionLabel = new JLabel("Type text in a field and press Enter.");
            actionLabel.setBorder(BorderFactory.createEmptyBorder(10,0,0,0));
            //Lay out the text controls and the labels.
            JPanel textControlsPane = new JPanel();
            GridBagLayout gridbag = new GridBagLayout();
            GridBagConstraints c = new GridBagConstraints();
            textControlsPane.setLayout(gridbag);
            JLabel[]labels = {textFieldLabel, textFieldLabel1,textFieldLabel2, textFieldLabel3, ftfLabel};
            JTextField[] textFields = {textField, startTime,textField2,totalTime, ftf};
            addLabelTextRows(labels, textFields, gridbag, textControlsPane);
            c.gridwidth = GridBagConstraints.REMAINDER; //last
            c.anchor = GridBagConstraints.WEST;
            c.weightx = 1.0;
            textControlsPane.add(actionLabel, c);
            textControlsPane.setBorder(
                    BorderFactory.createCompoundBorder(
                                    BorderFactory.createTitledBorder("Text Fields"),
                                    BorderFactory.createEmptyBorder(5,5,5,5)));
            //Create a text area.
            JTextArea textArea = new JTextArea(
            textArea.setFont(new Font("Serif", Font.ITALIC, 16));
            textArea.setLineWrap(true);
            textArea.setWrapStyleWord(true);
            JScrollPane areaScrollPane = new JScrollPane(textArea);
            areaScrollPane.setVerticalScrollBarPolicy(
                            JScrollPane.VERTICAL_SCROLLBAR_ALWAYS);
            areaScrollPane.setPreferredSize(new Dimension(250, 250));
            areaScrollPane.setBorder(
                BorderFactory.createCompoundBorder(
                    BorderFactory.createCompoundBorder(
                                    BorderFactory.createTitledBorder("Comment"),
                                    BorderFactory.createEmptyBorder(5,5,5,5)),
                    areaScrollPane.getBorder()));
            //Create an editor pane.
            JEditorPane editorPane = createEditorPane();
            JScrollPane editorScrollPane = new JScrollPane(editorPane);
            editorScrollPane.setVerticalScrollBarPolicy(
                            JScrollPane.VERTICAL_SCROLLBAR_ALWAYS);
            editorScrollPane.setPreferredSize(new Dimension(250, 145));
            editorScrollPane.setMinimumSize(new Dimension(10, 10));
            String[] initString =
            { "Meeting", "Lunch", "Holiday", "Sickness",
                     "Preparing report", "Administrative work", "Emails", "Query" };
            JList listCategories = new JList(initString);
            JScrollPane editorScrollPane = new JScrollPane(listCategories);
            editorScrollPane.setVerticalScrollBarPolicy(
                            JScrollPane.VERTICAL_SCROLLBAR_ALWAYS);
            editorScrollPane.setPreferredSize(new Dimension(250, 145));
            editorScrollPane.setMinimumSize(new Dimension(10, 10));
            //Create a text pane.
            JTextPane textPane = createTextPane();
            JScrollPane paneScrollPane = new JScrollPane(textPane);
            paneScrollPane.setVerticalScrollBarPolicy(
                            JScrollPane.VERTICAL_SCROLLBAR_ALWAYS);
            paneScrollPane.setPreferredSize(new Dimension(250, 155));
            paneScrollPane.setMinimumSize(new Dimension(10, 10));
            //Put the editor pane and the text pane in a split pane.
            JSplitPane splitPane = new JSplitPane(JSplitPane.VERTICAL_SPLIT,
                                                  editorScrollPane,
                                                  paneScrollPane);
            splitPane.setOneTouchExpandable(true);
            splitPane.setResizeWeight(0.5);
            JPanel rightPane = new JPanel(new GridLayout(1,0));
            rightPane.add(splitPane);
            rightPane.setBorder(BorderFactory.createCompoundBorder(
                            BorderFactory.createTitledBorder("Category of Task"),
                            BorderFactory.createEmptyBorder(5,5,5,5)));
            JPanel rightPane = new JPanel(new GridLayout(1,0));
            rightPane.add(editorScrollPane);
            //Put everything together.
            JPanel leftPane = new JPanel(new BorderLayout());
            leftPane.add(textControlsPane,
                         BorderLayout.PAGE_START);
            leftPane.add(areaScrollPane,
                         BorderLayout.CENTER);
            add(leftPane, BorderLayout.LINE_START);
            add(rightPane, BorderLayout.LINE_END);
            JButton button = new JButton("Submit");
            button.setCursor(Cursor.getDefaultCursor());
            //button.setMargin(new Insets(0,0,0,0));
            button.setActionCommand(buttonString);
            button.addActionListener(this);
            add(button, BorderLayout.SOUTH);
            button.addActionListener(new ActionListener()
                   public void actionPerformed(ActionEvent evt)
                        String toPrint = collectData();
                        newFile(toPrint);
       private String collectData()
              String toPrint = "";
              for (int i = 0; i < rowData.length; i++)
                   Component[] currentRowComps = rowData;
                   for (int j = 0; j < currentRowComps.length; j++)
                        Component currentComp = currentRowComps[j];
                        if (currentComp instanceof TextField)
                             TextField tf = (TextField) currentComp;
                             toPrint += tf.getText() + " - ";
                        else if (currentComp instanceof JComboBox)
                             JComboBox box = (JComboBox) currentComp;
                             Object selection = box.getSelectedItem();
                             if (selection != null)
                                  toPrint += selection.toString() + " - ";
                   toPrint += "\n";
              return toPrint;
         private File newFile(String data)
              File newfile = null;
              try
                   newfile = new File("I:\\ouput.doc");
                   System.out.println("DATA? - " + data);
                   FileOutputStream fos = new FileOutputStream(newfile);
                   fos.write(data.getBytes());
                   fos.close();
                   // JOptionPane.showMessageDialog(null, "Save File");
                   JOptionPane.showMessageDialog(null, "File saved.", "Success",
                   JOptionPane.INFORMATION_MESSAGE);
              catch (IOException ioexc)
                   JOptionPane.showMessageDialog(null, "Error while saving file: " + ioexc,
                   "Error", JOptionPane.ERROR_MESSAGE);
              return null;
    private void addLabelTextRows(JLabel[] labels,
    JTextField[] textFields,
    GridBagLayout gridbag,
    Container container) {
    GridBagConstraints c = new GridBagConstraints();
    c.anchor = GridBagConstraints.EAST;
    int numLabels = labels.length;
    for (int i = 0; i < numLabels; i++) {
    c.gridwidth = GridBagConstraints.RELATIVE; //next-to-last
    c.fill = GridBagConstraints.NONE; //reset to default
    c.weightx = 0.0; //reset to default
    container.add(labels[i], c);
    c.gridwidth = GridBagConstraints.REMAINDER; //end row
    c.fill = GridBagConstraints.HORIZONTAL;
    c.weightx = 1.0;
    container.add(textFields[i], c);
    public void actionPerformed(ActionEvent e) {
    String prefix = "You typed \"";
    if (textFieldString2.equals(e.getActionCommand()))
    JTextField source = (JTextField)e.getSource();
    actionLabel.setText(prefix + source.getText() + "\"");
    java.text.SimpleDateFormat sdf = new java.text.SimpleDateFormat("H:mm");
    try {
                        java.util.Date end = sdf.parse(source.getText());
                        java.util.Date start = sdf.parse(startTime.getText());
                        long difference = (end.getTime() - start.getTime()) / 60000;
                        totalTime.setText(Long.toString(difference));
                   } catch (ParseException e1) {
                        // TODO Auto-generated catch block
                        e1.printStackTrace();
    if (textFieldString1.equals(e.getActionCommand()))     {JTextField source = (JTextField)e.getSource();
            actionLabel.setText(prefix + source.getText() + "\"");}
    if (textFieldString2.equals(e.getActionCommand()))     {JTextField source = (JTextField)e.getSource();
            actionLabel.setText(prefix + source.getText() + "\"");}
    if (textFieldString3.equals(e.getActionCommand()))     {JTextField source = (JTextField)e.getSource();
            actionLabel.setText(prefix + source.getText() + "\"");}
    else if (textFieldString.equals(e.getActionCommand())) {
    //JPasswordField source = (JPasswordField)e.getSource();
    //actionLabel.setText(prefix + new String(source.getPassword())
    //+ "\"");
    } else if (buttonString.equals(e.getActionCommand())) {
    Toolkit.getDefaultToolkit().beep();
    private JEditorPane createEditorPane() {
    JEditorPane editorPane = new JEditorPane();
    editorPane.setEditable(false);
    java.net.URL helpURL = DD.class.getResource(
    "DailyDairyDemoHelp.html");
    if (helpURL != null) {
    try {
    editorPane.setPage(helpURL);
    } catch (IOException e) {
    System.err.println("Attempted to read a bad URL: " + helpURL);
    } else {
    System.err.println("Couldn't find file: Daily Dairy.html");
    return editorPane;
         private JTextPane createTextPane() {
    String[] initString =
    { "Meeting", "Lunch", "Holiday", "Sickness",
         "Preparing report", "Administrative work", "Emails", "Query" };
    String[] initStyles =
    { "regular", "italic", "bold", "small", "large",
    "regular", "button", "regular", "icon",
    "regular"
    JTextPane textPane = new JTextPane();
    StyledDocument doc = textPane.getStyledDocument();
    addStylesToDocument(doc);
    try {
    for (int i=0; i < initString.length; i++) {
    doc.insertString(doc.getLength(), initString[i],
    doc.getStyle(initStyles[i]));
    } catch (BadLocationException ble) {
    System.err.println("Couldn't insert initial text into text pane.");
    return textPane;
    protected void addStylesToDocument(StyledDocument doc) {
    //Initialize some styles.
    Style def = StyleContext.getDefaultStyleContext().
    getStyle(StyleContext.DEFAULT_STYLE);
    Style regular = doc.addStyle("regular", def);
    StyleConstants.setFontFamily(def, "SansSerif");
    Style s = doc.addStyle("italic", regular);
    StyleConstants.setItalic(s, true);
    s = doc.addStyle("bold", regular);
    StyleConstants.setBold(s, true);
    s = doc.addStyle("small", regular);
    StyleConstants.setFontSize(s, 10);
    s = doc.addStyle("large", regular);
    StyleConstants.setFontSize(s, 16);}
    /*s = doc.addStyle("icon", regular);
    StyleConstants.setAlignment(s, StyleConstants.ALIGN_CENTER);
    ImageIcon pigIcon = createImageIcon("images/Pig.gif",
    "a cute pig");
    if (pigIcon != null) {
    StyleConstants.setIcon(s, pigIcon);
    s = doc.addStyle("button", regular);
    StyleConstants.setAlignment(s, StyleConstants.ALIGN_CENTER);
    ImageIcon soundIcon = createImageIcon("images/sound.gif",
    "sound icon");
    JButton button = new JButton();
    if (soundIcon != null) {
    button.setIcon(soundIcon);
    } else {
    button.setText("BEEP");
    button.setCursor(Cursor.getDefaultCursor());
    button.setMargin(new Insets(0,0,0,0));
    button.setActionCommand(buttonString);
    button.addActionListener(this);
    StyleConstants.setComponent(s, button);
    /** Returns an ImageIcon, or null if the path was invalid. */
    protected static ImageIcon createImageIcon(String path,
    String description) {
    java.net.URL imgURL = DD.class.getResource(path);
    if (imgURL != null) {
    return new ImageIcon(imgURL, description);
    } else {
    System.err.println("Couldn't find file: " + path);
    return null;
    * Create the GUI and show it. For thread safety,
    * this method should be invoked from the
    * event dispatch thread.
    private static void createAndShowGUI() {
    //Create and set up the window.
    JFrame frame = new JFrame("DailyDairyDemo");
    frame.setDefaultCloseOperation(JFrame.EXIT_ON_CLOSE);
    //Add content to the window.
    frame.add(new DD());
    //Display the window.
    frame.pack();
    frame.setVisible(true);
    public static void main(String[] args) {
    //Schedule a job for the event dispatching thread:
    //creating and showing this application's GUI.
    SwingUtilities.invokeLater(new Runnable() {
    public void run() {
    //Turn off metal's use of bold fonts
              UIManager.put("swing.boldMetal", Boolean.FALSE);
              createAndShowGUI();
    And here is the code for the table.
    import java.awt.*;
    import java.awt.event.*;
    import java.util.*;
    import java.io.*;
    import java.util.Date;
    import java.sql.*;
    import java.text.*;
    import javax.swing.*;
    import javax.swing.border.*;
    import javax.swing.event.*;
    import javax.swing.table.*;
    public class DDTable extends JFrame{
         protected JTable m_table;
         protected DDTableData m_data;
         protected JLabel m_title;
         public DDTable(){
              super("DDTABLE");
              setSize(600, 300);
              UIManager.put("Table.focusCellHighlightBorder",new LineBorder(Color.black, 0));
              m_data = new DDTableData();
              m_title = new JLabel(m_data.getTitle(), SwingConstants.CENTER);
              m_title.setFont(new Font("Helvetica", Font.PLAIN, 24));
              getContentPane().add(m_title, BorderLayout.NORTH);
              m_table = new JTable();
              m_table.setAutoCreateColumnsFromModel(false);
              m_table.setModel(m_data);
              for (int k = 0; k < m_data.getColumnCount(); k++) {
                   DefaultTableCellRenderer renderer = new DefaultTableCellRenderer();
                   renderer.setHorizontalAlignment(DDTableData.m_columns[k].m_alignment);
                   TableColumn column = new TableColumn(k, DDTableData.m_columns[k].m_width, renderer, null);
                   m_table.addColumn(column);
              JTableHeader header = m_table.getTableHeader();
              header.setUpdateTableInRealTime(false);
              setJMenuBar(createMenuBar());
              JScrollPane ps = new JScrollPane();
              ps.getViewport().setBackground(m_table.getBackground());
              ps.getViewport().add(m_table);
              getContentPane().add(ps, BorderLayout.CENTER);
              protected JMenuBar createMenuBar(){
                   JMenuBar menuBar = new JMenuBar();
                   JMenu mFile = new JMenu("File");
                   mFile.setMnemonic('f');
                   Action actionNew = new AbstractAction("New Appointment"){
                        public void actionPerformed(ActionEvent e){
                             if (!promptToSave())
                                  return;
                             newDocument();
                        JMenuItem item = new JMenuItem(actionNew);
                        item.setMnemonic('n');
                        item.setAccelerator(KeyStroke.getKeyStroke(KeyEvent.VK_N, InputEvent.CTRL_MASK));
                        mFile.add(item);
                        Action actionSave = new AbstractAction("Save Appointment"){
                             public void actionPerformed(ActionEvent e){
                                  boolean m_textChanged = false;
                                  if (!m_textChanged)
                                       return;
                                  saveFile(false);
                              item = new JMenuItem(actionSave);
                             item.setMnemonic('s');
                             item.setAccelerator(KeyStroke.getKeyStroke(KeyEvent.VK_S, InputEvent.CTRL_MASK));
                             mFile.add(item);
                   JMenuItem mData = new JMenuItem("Retrieve Data");
                   mData.setMnemonic('r');
                   ActionListener lstData = new ActionListener(){
                   public void actionPerformed(ActionEvent e){
                        retrieveData();
                   mData.addActionListener(lstData);
                   mFile.add(mData);
                   mFile.addSeparator();
                   JMenuItem mExit = new JMenuItem("Exit");
                   mExit.setMnemonic('x');
                   ActionListener lstExit = new ActionListener(){
                        public void actionPerformed(ActionEvent e){
                             System.exit(0);
                   mExit.addActionListener(lstExit);
                   mFile.add(mExit);
                   menuBar.add(mFile);
                   return menuBar;
              protected void saveFile(boolean b) {
                   // TODO Auto-generated method stub
              protected void newDocument() {
                     //Create and set up the window.
                 JDialog frame = new JDialog();//"DailyDairyDemo");
                 frame.setModal(true);
                 //frame.setDefaultCloseOperation(JFrame.EXIT_ON_CLOSE);
                 //Add content to the window.
                 frame.add(new DD());
                 //Display the window.
                 frame.pack();
                 frame.setVisible(true);
                 JOptionPane.showMessageDialog(this, "Done!");
                 //loadFile();
              protected boolean promptToSave() {
                   // TODO Auto-generated method stub
                   return true;
              public void retrieveData(){
                   Runnable updater = new Runnable(){
                        public void run(){
                             SimpleDateFormat frm = new SimpleDateFormat("MM/dd/yyyy");
                             String currentDate = frm.format(m_data.m_date);
                             String result =
                             (String)JOptionPane.showInputDialog(DDTable.this,"Please enter date in form mm/dd/yyyy:", "Input", JOptionPane.INFORMATION_MESSAGE, null, null, currentDate);
                             if (result==null)
                                  return;
                             java.util.Date date = null;
                             try{
                                  date = frm.parse(result);
                             catch (java.text.ParseException ex){
                                  date = null;
                             if (date == null){
                                  JOptionPane.showMessageDialog(DDTable.this, result+" is not a valid date", "Warning", JOptionPane.WARNING_MESSAGE);
                                  return;
                             setCursor(Cursor.getPredefinedCursor(Cursor.WAIT_CURSOR));
                             try{
                                  m_data.retriveData(date);
                             catch (Exception ex){
                                  JOptionPane.showMessageDialog(DDTable.this,"Error retrieving data:\n"+ex.getMessage(),"Error",JOptionPane.ERROR_MESSAGE);
                             setCursor(Cursor.getPredefinedCursor(Cursor.DEFAULT_CURSOR));
                             m_title.setText(m_data.getTitle());
                             m_table.tableChanged(new TableModelEvent(m_data));
                   SwingUtilities.invokeLater(updater);
         public static void main(String argv[]){
              DDTable frame = new DDTable();
              frame.setDefaultCloseOperation(JFrame.EXIT_ON_CLOSE);
              frame.setVisible(true);
       class DDData{
            public String m_name;
            public String m_date;
            public String m_startTime;
            public String m_endTime;
            public String m_totalTime;
            public String m_comment;
            public String m_category;
            public DDData(String name, String date,String startTime, String endTime, String totalTime, String comment, String category){
                 m_name = name;
                 m_date = date;
                 m_startTime = startTime;
                 m_endTime = endTime;
                 m_totalTime = totalTime;
                 m_comment = comment;
                 m_category = category;
       class ColumnData{
            public String m_title;
            public int m_width;
            public int m_alignment;
            public ColumnData(String title, int width, int alignment) {
                 m_title = title;
                 m_width = width;
                 m_alignment = alignment;
       class DDTableData extends AbstractTableModel{
         private static final long serialVersionUID = 1L;
         static final String QUERY = "SELECT symbols.name,"+"data startTime, data.endTime, data.totalTime, data.comment, data.category FROM DATA INNER JOIN SYMBOLS"
         +"ON DATA.symbol = SYMBOLS.symbol WHERE"+
         "month(data.date1)=? AND day(data.date1)=?"+
         "AND year(data.date1)=?";
         @SuppressWarnings("unchecked")
         public void retriveData(Date date)
         throws SQLException, ClassNotFoundException {
              try {
                   File f = new File("appointments.dat");
                   FileInputStream fis = new FileInputStream(f);
                ObjectInputStream ois = new ObjectInputStream(fis);
                m_vector = (Vector<DDData>) ois.readObject();
                ois.close();
                fis.close();
               } catch(ClassCastException ex) {
               } catch(FileNotFoundException ex) {
               } catch(IOException ex) {
              /*GregorianCalendar calendar = new GregorianCalendar();
              calendar.setTime(date);
              int month = calendar.get(Calendar.MONTH)+1;
              int day = calendar.get(Calendar.DAY_OF_MONTH);
              int year = calendar.get(Calendar.YEAR);
              m_date = date;
              m_vector = new Vector();
              Connection conn = null;
              PreparedStatement pst = null;
              try{
                   //Load the JDBC-ODBC bridge driver
                   Class.forName("sun.jdbc.odbc.JdbcOdbcDriver");
                   conn = DriverManager.getConnection("jdbc:odbc:Market", "admin", "");
                   pst = conn.prepareStatement(QUERY);
                   pst.setInt(1, month);
                   pst.setInt(2, day);
                   pst.setInt(3, year);
                   ResultSet results = pst.executeQuery();
                   while (results.next()){
                        String name = results.getString(1);
                        String startTime = results.getString(2);
                        String endTime = results.getString(3);
                        String totalTime = results.getString(4);
                        String comment = results.getString(5);
                        String category = results.getString(6);
                        m_vector.addElement(new DDData(name, startTime, endTime, totalTime, comment, category, category));
                   sortData();
              finally{
                   if (pst != null )
                        pst.close();
                   if (conn != null)
                        conn.close();
         private void saveData() {
              try {
                   File f = new File("appointments.dat");
                   FileOutputStream fos = new FileOutputStream(f);
                ObjectOutputStream oos = new ObjectOutputStream(fos);
                oos.writeObject(m_vector);
                oos.close();
                fos.close();
               } catch(IOException ex) {
         private void sortData() {
              // TODO Auto-generated method stub
         static final public ColumnData m_columns[] = {
                 new ColumnData("Name", 100, JLabel.LEFT),
                 new ColumnData("Date", 100, JLabel.LEFT),
                 new ColumnData("Start Time", 100, JLabel.RIGHT),
                 new ColumnData("End Time", 100, JLabel.RIGHT),
                 new ColumnData("Total Time", 100, JLabel.RIGHT),
                 new ColumnData("Comment", 200, JLabel.RIGHT),
                 new ColumnData("Category", 100, JLabel.RIGHT),
            protected SimpleDateFormat m_frm;
            protected Vector<DDData> m_vector = new Vector<DDData>();
            protected Date m_date;
            public DDTableData(){
                 m_frm = new SimpleDateFormat("MM/dd/yyyy");
                 setDefaultData();
            public void setDefaultData(){
                 try{
                      m_date = m_frm.parse("07/31/2007");
                 catch (java.text.ParseException ex){
                      m_date = null;
                 m_vector.removeAllElements();
                 m_vector.addElement(new DDData("Jerome", null, "Dan", null, null, null, null));
            public int getRowCount(){
                 return m_vector==null ? 0 : m_vector.size();
            public int getColumnCount(){
                 return m_columns.length;
            public String getColumnName(int column){
                 return m_columns[column].m_title;
            public boolean isCellEditable(int nRow, int nCol){
                 return false;
            public Object getValueAt(int nRow, int nCol){
                 if (nRow < 0 || nRow>=getRowCount())
                      return "";
                 DDData row = m_vector.elementAt(nRow);
                 switch (nCol){
                 case 0: return row.m_name;
                 case 1: return row.m_date;
                 case 2: return row.m_startTime;
                 case 3: return row.m_endTime;
                 case 4: return row.m_totalTime;
                 case 5: return row.m_comment;
                 case 6: return row.m_category;
                 return "";
            public String getTitle(){
                 if (m_date==null)
                      return "Daily Dairy";
                 return "Daily Dairy at "+m_frm.format(m_date);

    here is code to collect the data pls what can i do to get the data on the form display on the JTable in the all categories as on the form pls...
    private String collectData()
              String toPrint = "";
              for (int i = 0; i < rowData.length; i++)
                   Component[] currentRowComps = rowData;
                   for (int j = 0; j < currentRowComps.length; j++)
                        Component currentComp = currentRowComps[j];
                        if (currentComp instanceof TextField)
                             TextField tf = (TextField) currentComp;
                             toPrint += tf.getText() + " - ";
                        else if (currentComp instanceof JComboBox)
                             JComboBox box = (JComboBox) currentComp;
                             Object selection = box.getSelectedItem();
                             if (selection != null)
                                  toPrint += selection.toString() + " - ";
                   toPrint += "\n";
              return toPrint;
         private File newFile(String data)
              File newfile = null;
              try
                   newfile = new File("I:\\ouput.doc");
                   System.out.println("DATA? - " + data);
                   FileOutputStream fos = new FileOutputStream(newfile);
                   fos.write(data.getBytes());
                   fos.close();
                   // JOptionPane.showMessageDialog(null, "Save File");
                   JOptionPane.showMessageDialog(null, "File saved.", "Success",
                   JOptionPane.INFORMATION_MESSAGE);
              catch (IOException ioexc)
                   JOptionPane.showMessageDialog(null, "Error while saving file: " + ioexc,
                   "Error", JOptionPane.ERROR_MESSAGE);
              return null;
    private void addLabelTextRows(JLabel[] labels,
    JTextField[] textFields,
    GridBagLayout gridbag,
    Container container) {
    GridBagConstraints c = new GridBagConstraints();
    c.anchor = GridBagConstraints.EAST;
    int numLabels = labels.length;
    for (int i = 0; i < numLabels; i++) {
    c.gridwidth = GridBagConstraints.RELATIVE; //next-to-last
    c.fill = GridBagConstraints.NONE; //reset to default
    c.weightx = 0.0; //reset to default
    container.add(labels[i], c);
    c.gridwidth = GridBagConstraints.REMAINDER; //end row
    c.fill = GridBagConstraints.HORIZONTAL;
    c.weightx = 1.0;
    container.add(textFields[i], c);
    Message was edited by:
    desaint
    Message was edited by:
    desaint

  • Cannot display all the tables of the schema!!!

    Hi:
    I use the oracle sql developer on the windows xp, I found that the tables tab cannot display all the tables of the schema owner, I use the sql "select count(*) from user_tables" I found the result is more than the tab can be display, and I also press the "show more" already.... does anyone can help me ???

    Similarly, I have 852 tables owned by the connected user (selected count from user_tables and checked the user tables report which has this many records returned), but when I double-click on the "Show More" and select Show All, I only get approximately 375 tables listed.
    It doesn't help that the sorting is different - ie ASF_ comes before ASFB in the connection pane but the other way around in the report.
    However, it looks as though the problem is that tables that are not analysed (based on the report data in DATE_LAST_ANALYZED) are not being displayed under the Table node.

  • Dialog Prog to Display fields of Table or Structure in screen dynamically.

    Hello Experts ,
           I am working on a dialog programming I wish to display any given table/structure on the screen - to be very clear.
    1st screen -
        One input box which can take any SAP standard or custom tableor structure as input <-- Press enter
    2 nd screen -
        I wish to see the fields of the structure in column format dsiplayed in the screen ( Like ALV Grid in the page).
    Please tell me the logic or similar example so i can refer thanks in advance.
    Thanks,
    Sriram.

    Hello Srinivas,
      Your program looks really looks and simple but the porb is we have 4.6c here. So the syntax lines
    CREATE DATA gv_dref TYPE TABLE OF (p_table).
       is not accepted by the system if we enter as it is (error - unable to interpret table - possible cause of error or spelling) 
    but it accepts
    CREATE DATA gv_dref TYPE p_table.
    but at the time of select query its not talking it has a internal table to show data , finalltyit dumps.
    [ASSIGN gv_dref->* TO <fs_itab>.
      "Select the data
      SELECT * FROM (p_table) INTO TABLE <fs_itab> UP TO 100 ROWS.
    So my problem is to find a way to dynamically display a table or view .
    Please guide.
    Regards,
    Sriram.

  • How to display a oracle table from a java program?

    How to display a oracle table from a java program.
    Hello friends, I have written a Java program, using oracle 10g as backend.
    I want to display a oracle table as output. Im not getting how to display oracle table as a output table.. Pls help me
    Thank you

    jayanthds, you're not going to get a satisfactory
    answer to this here. it's too big a task to justbe
    quickly outlined in a forum - the reply "all youneed
    to do is to query you table and return it asJTable"
    is worthless, for example, since the solution to
    any problem can be distilled to such a
    soundbite, if need be. doesn't make the solutionany
    simpler
    essentially you're asking "how do I write adatabase
    application?". all you'll get is snippets of code
    that, when fitted together, will eventually helpyou
    do this, but you'll spend days and days comingback
    saying "right, I've done that, now what?" until
    either you or the forum gets frustrated with the
    whole affair and the process stops
    there are entire books written about this subject,
    and countless tutorials and guides on theinternet.
    you're better off going down that routehehehe.well, it's true! I used to have a manager that would outline the solution to a problem in a few lines of pseudocode, and then firmly believe that the actual solution would be just as brief and simple. shame his pseudocode included such lofty abstractions as "reformat all data"

  • Colors in Dynamic ALV table display

    Hello All,
    I have dynamic ALV table display in which i created the columns dynamically and finally binded that created node and diplayed the table ..
    Now what i want to do is depending on some condition i need to change the colors in the table display..
    I tried to set the color in this way inside the loop .
                     if lv_phase  = '3'.
                   lr_column->set_cell_design( CL_WD_TABLE_COLUMN=>E_CELL_DESIGN-badvalue_medium ).
                     else.
                    lr_column->set_cell_design( CL_WD_TABLE_COLUMN=>E_CELL_DESIGN-standard ).
                   endif.
    This piece of code either changes all the coloumns into one color only why it is not changing the color based upon the condition . I am unable to understand..
    Please help me in this...Do i need to some thing else..

    Solved by creating a new column called cell design ... and settign the set_cell_design_fieldname ...
    This solved my Problem ..

  • Displaying no default zeroes for the numeric field in the table display.

    hi folks,
         I am binding a table in the context which has some numeric fields. I'm  displaying the same table which has some records for editing purpose. But the problem is that the numeric  field column is being displayed with zeros if it doesnot have any value in it. Can u explain how to disable the zeroes by not displaying them by defualt when there is no value for the numeric field.
    regards,
    Ramu

    set the format of the context attribute TEST is the context attribute name
    data: lr_info type ref to if_wd_context_node_info.
    data: ls_prop type WDY_ATTRIBUTE_FORMAT_PROP.
    lr_info = wd_context->get_node_info( ).
    ls_prop = lr_info->GET_ATTRIBUTE_FORMAT_PROPS( name = 'TEST' ).
    LS_PROP-NULL_AS_BLANK = 'X'.
    lr_info->sET_ATTRIBUTE_FORMAT_PROPS( name = 'TEST'
                 FORMAT_PROPERTIES = ls_prop ).
    Abhi

  • Spry Table displaying blank in IE9

    Spry table created in XML using CS5 (SpryData.js - version 0.52 - Spry Pre-Release 1.6.1) at http://www.jacquipatterson.com.au/slideshow_celebrant.html
    The table displays as required in Firefox, Chrome, Navigator but draws a blank page with IE9. I have searched all over for a similar case but to no avail.
    I would be most praisefull if someone has a solution to this annoying problem or has a suggestion on how to get around it.

    Change line 35 to
    var slides_120609 = new Spry.Data.XMLDataSet("http://www.jacquipatterson.com.au/Slideshowjune.xml", "Root/Row", {sortOnLoad: "venue", sortOrderOnLoad: "ascending"});
    and remove line 195
    Gramps

  • Setting leadselection does not change displayed row in table

    I am using a Table element to display a list of search results.
    The first time I perform a query, the results appear and the first row is displayed. The table footer shows the total amount of rows and the buttons to navigate. So far, so good.
    The problem occurs when I perform a new query, after having navigated through the rows and the table was for example showing row number 10.
    I perform the new query (which sets the leadselection back to 0), but the table stays on row 10, or the row closest to that number. It does not jump to the first row. Or in other words, the table view does not "reset".
    Any ideas?

    You right, it will not automatically navigate to the first row.
    Set  firstVisibleRow property of the table UI element to zero everytime you execute the search.
    Abhi

Maybe you are looking for