Must double click JTable cell to edit - Why?

Hi there,
I have a custom JTable model, which overrides the isCellEditable method and returns true for the first column. All nice, only that column now gets editable - but why do I have to double click in the cell to be able to edit in it? I've seen swing gui's where the cell gets editable on single click/focus...
Very thankful for any help in resolving this!
Best regard,
AC

Add a mouselistener to your table and in the mousePressed() method set the editing cell:
table.editCellAt(row, column);
table.setEditingRow(row);
table.setEditingColumn(column);
table.repaint();

Similar Messages

  • How do I get the line above the tasks, which allows you to edit the cell contents, without double clicking the cell?

    As title says.
    Normally in Gantt Chart View, above the tasks there's a line which displays the contents of the cell you have selected, and allows you to edit the contents without having to double click the cell.
    In my case, this line is not there, and it is slightly hindering my work.
    So, does anyone know where I should go to re-enable this line?
    Thanks a lot!

    Hi,
    Go to file, then options, then display and check the "entry bar" option.
    http://www.manageprojectsonsharepoint.com/blog/2012/04/02/microsoft-project-quick-tip-entry-bar/
    Hope this helps.
    Guillaume Rouyre - MBA, MCP, MCTS

  • Iphoto wont play movie files and wont double click for zoom or edit

    Hi i bought my first ever macbook a week ago,love everything on it,iphoto worked well but today i wanted to show someone a movie file on my camea which i have in my iphoto libray clicked on it and it usually opens,today nothing!!! this file has opened loads before because its a holiday movie, loads of people have seen it but now nothing.
    Also my double click to zoom or edit preference seems to do nothing whichever box you check in preffence nothing happens.
    Being new to mac i hope i can find some answers!!
    Chris

    Chris:
    Welcome to the Apple Discussions. First Control+click on the movie's thumbnail and select Show File from the contextual menu. When you get to the original movie file double click on it to see if you can open it in Quicktime. If not then it's more a QT issue. If it opens OK in QT go to the next procedure.
    Delete the iPhoto preference file, com.apple.iPhoto.plist, that resides in your User/Library/Preferences folder and try again. If iPhoto is still misbehaving log into another account and try the same operations in iPhoto there. If still not working you may have to reinstall iPhoto from the disk it came one. To do so you'll have to delete the current application and all files with "iPhoto" in the file name that reside in the HD/Library/Receipts folder. After you get iPhoto reinstalled run the latest update for it, 7.1.3 if needed.
    TIP: For insurance against the iPhoto database corruption that many users have experienced I recommend making a backup copy of the Library6.iPhoto (iPhoto.Library for iPhoto 5 and earlier) database file and keep it current. If problems crop up where iPhoto suddenly can't see any photos or thinks there are no photos in the library, replacing the working Library6.iPhoto file with the backup will often get the library back. By keeping it current I mean backup after each import and/or any serious editing or work on books, slideshows, calendars, cards, etc. That insures that if a problem pops up and you do need to replace the database file, you'll retain all those efforts. It doesn't take long to make the backup and it's good insurance.
    I've created an Automator workflow application (requires Tiger or later), iPhoto dB File Backup, that will copy the selected Library6.iPhoto file from your iPhoto Library folder to the Pictures folder, replacing any previous version of it. It's compatible with iPhoto 6 and 7 libraries and Tiger and Leopard. iPhoto does not have to be closed to run the application, just idle. You can download it at Toad's Cellar. Be sure to read the Read Me pdf file.≤br>
    Note: There now an Automator backup application for iPhoto 5 that will work with Tiger or Leopard.

  • JTable cell being edited after model changed.

    I have a fairly simple JTable, with a implementation of AbstractTableModel supplying the data. The cells are edited by using a JComboBox. I wrap these into a DefaultCellEditor. I have a KeyListener attached to the JTable listening for VK_DELETE, and when it finds one, instructs the model to delete the row represented by the selected row in the table.
    Everything works fine until I want to delete a row from the table. My scenario is:
    - I click in a cell, and the editor opens.
    - I select an entry in the list. The editor closes, the result is rendered, and the wee yellow box around the cell is shown
    - I hit the delete key.
    - My key listener picks up the event, and informs the model to delete the row. I remove the row from the model and invoke fireTableDataChanged().
    The result is that the row is deleted, but the table ends up with the cell editor deployed on the cell of the row below (which is now at the same row as the one I just deleted).
    My tracing shows that the isCellEditable is called on the model after the delete. I don't know why.
    Can anyone explain how to prevent this or what might be causing the table to think that the cell needs editing?
    Thanks, Andrew

    It will do whatever is the default. I wrap the JComboBox in a DefaultCellEditor. I can't see how the editor is involved at this point, or why the editor becomes involved after the row has been deleted.
    Remember, at the time that I hit the delete key, there is no editor rendered or visible. I have the JTable displayed, a row selected, and the yellow box around one of the (editable but not currently being edited) cells. This has been achieved by editing a cell (displaying the cell editor - a combo box) and selecting an entry. The editor is removed, and the cell displayed with the (default) cell renderer for the table.
    The delete action is caught by the listener on the table, the model is instructed to delete a row from its underlying data, which fires a fireTableDataChanged event.
    That is all I do. After that it is all swing. The table model starts getting asked about cells being editable after I have finished deleting the row. I'll post the relevant code below if that helps.
    The datamodel is of class ConstraintTableModel (see below) and the column model is of class DefaultTableColumnModel
    JTable table = new JTable( dataModel, columnModel );The column model is defined liike so:
    columnModel = new DefaultTableColumnModel();
    TableColumn labelColumn = new TableColumn(ConstraintTableModel.LABEL_COLUMN);
    labelColumn.setHeaderValue( dataModel.getColumnName(ConstraintTableModel.LABEL_COLUMN));
    labelColumn.setPreferredWidth( 5 );
    labelColumn.setMaxWidth( 5 );
    labelColumn.setResizable( false );
    TableColumn taskColumn = new TableColumn(ConstraintTableModel.TASK_COLUMN);
    taskColumn.setHeaderValue( dataModel.getColumnName(ConstraintTableModel.TASK_COLUMN));
    TableColumn typeColumn = new TableColumn(ConstraintTableModel.TYPE_COLUMN);
    typeColumn.setHeaderValue( dataModel.getColumnName(ConstraintTableModel.TYPE_COLUMN));
    columnModel.addColumn( labelColumn );
    columnModel.addColumn( taskColumn );
    columnModel.addColumn( typeColumn );I add the key listener like so:
    table.addKeyListener( new KeyAdapter()
        public void keyPressed( KeyEvent e )
          if( e.getKeyCode() == KeyEvent.VK_DELETE )
            log.debug("Delete pressed in listener attached to table ");
            JTable t = (JTable) e.getSource();
            int selectedRow = t.getSelectedRow();
            if( selectedRow >= 0 )
              log.debug("  Removing row " + selectedRow);
              ((ConstraintTableModel)t.getModel()).removeRow(selectedRow);
            log.debug("Finished with key press");
      } );The cell editor is created like this:
    JComboBox taskEditorComponent = new JComboBox( tasksModel );
    taskEditorComponent.setFont( GanttChart.tableFont );
    taskEditorComponent.setBackground( Color.WHITE );
    DefaultCellEditor taskEditor = new DefaultCellEditor(taskEditorComponent);
    taskEditor.setClickCountToStart( 1 );
    table.setDefaultEditor( GanttTask.class, taskEditor );The model is coded like so:
    class ConstraintTableModel extends AbstractTableModel
        // Constants
        public static final int LABEL_COLUMN = 0;
        public static final int TASK_COLUMN = 1;
        public static final int TYPE_COLUMN = 2;
        private Vector          columnNames;
        private ArrayList       dataRows;
        public ConstraintTableModel()
            super();
            this.buildDataVector();
            this.addPrimerRow();
         * Every row in the table is a GanttConstraint. Therefore when deciding what to
         * display in any particular column of the table, we need to determine what the
         * column is, and then use the informatino in the GanttConstraint to go out to the
         * lookup and get the relevant object, and value to display.
        public Object getValueAt( int row, int col )
            Object          returnObject = "";
            GanttConstraint aConstraint = (GanttConstraint) this.getDataRows().get( row );
            // We're rendering the task column. If there's no task id (partially filled in row)
            // return blank otherwise return the master task
            else if( col == ConstraintTableModel.TASK_COLUMN )
                if( aConstraint.getMasterId() != null )
                    GanttTask masterTask = (GanttTask) real.getLookup().get( aConstraint.getMasterId() );
                    returnObject = masterTask;
            // We're rendering the type column. If there's no type (partially filled in row)
            // return blank otherwise return the constraint type
            else if( col == ConstraintTableModel.TYPE_COLUMN )
                if( aConstraint.getType() != null )
                    GanttConstraintType constraintType = (GanttConstraintType) GanttConstraintType.getConstraintTypes()
                                                                                                     .get( aConstraint.getType()
                                                                                                                      .intValue() );
                    returnObject = constraintType;
            return returnObject;
         * When we receive this message, we are handed an object of the type specified in
         * getColumnClass. We need to take this object and place the relevant information into
         * the GanttConstraint row in the table model.
         * Depending on whether the row being modified is an existing row or a new row, set
         * the state of the constraint appropriately.
         * @see javax.swing.table.TableModel#setValueAt(java.lang.Object, int, int)
        public void setValueAt( Object value, int row, int col )
            log.debug( "+setValueAt (row/col) " + row + "/" + col );
            if ( value == null )
                log.debug( "  handed a null value. Returning" );
                return;
            GanttConstraint aConstraint = (GanttConstraint) this.getDataRows().get( row );
            // If we are modifying the primer row, add another primer row.
            if( row == ( this.getRowCount() - 1 ) ) // Last row is always the primer
                log.debug( "  adding a primer row" );
                this.addPrimerRow();
            // We're modifying the Task data. Get the GanttTask handed to us and place it
            // into the master slot in the constraint.
            if( col == ConstraintTableModel.TASK_COLUMN ) // Task
                log.debug( "  updating the master task" );
                GanttTask selectedTask = (GanttTask) value;
                aConstraint.setMaster( selectedTask );
            // We're modifying the Type data. Get the GanttConstraintType handed to us and place it
            // into the type slot in the constraint.
            if( col == ConstraintTableModel.TYPE_COLUMN ) // Constraint type
                log.debug( "  updating the constraint type" );
                GanttConstraintType selectedConstraintType = (GanttConstraintType) value;
                aConstraint.setType( selectedConstraintType.getType() );
            log.debug( "-setValueAt" );
        public Class getColumnClass( int col )
            Class columnClass = super.getColumnClass( col );
            if( col == ConstraintTableModel.LABEL_COLUMN )
                columnClass = String.class;
            if( col == ConstraintTableModel.TASK_COLUMN )
                columnClass = GanttTask.class;
            if( col == ConstraintTableModel.TYPE_COLUMN )
                columnClass = GanttConstraintType.class;
            return columnClass;
        // We are handing the data storage
        public void setDataRows( ArrayList dataRows )
            this.dataRows = dataRows;
        public boolean isCellEditable( int row, int col )
            log.debug( "+isCellEditable (row/col) " + row + "/" + col );
            if( !real.canEdit() )
                return false;
            if( ( col == ConstraintTableModel.TASK_COLUMN ) ||
                    ( col == ConstraintTableModel.TYPE_COLUMN ) )
                return true;
            else
                return false;
        // We are handing the data storage
        public ArrayList getDataRows()
            return this.dataRows;
        public String getColumnName( int column )
            return (String) this.getColumnNames().get( column );
         * Clean up rows that do not have both the master task and type set. Not interested in them
        public void removeDirtyRows()
            log.debug( "+removeDirtyRows" );
            Iterator dataIterator = this.getDataRows().iterator();
            while( dataIterator.hasNext() )
                GanttConstraint element = (GanttConstraint) dataIterator.next();
                if( ( element.getMasterId() == null ) || ( element.getType() == null ) )
                    element.setTransient();
                    dataIterator.remove();
            fireTableDataChanged();
            log.debug( "-removeDirtyRows" );
        public void removeRow( int row )
            log.debug( "+removeRow(" + row + ")" );
            if( row < this.getDataRows().size() )
                GanttConstraint aConstraint = (GanttConstraint) this.getDataRows().get( row );
                this.getDataRows().remove( row );
                if( aConstraint.isClone() )
                    aConstraint.setDeleted();
                else
                    aConstraint.setTransient();
                    getClone().removeConstraint( aConstraint );
                fireTableDataChanged();
            if( this.getRowCount() == 0 )
                this.addPrimerRow();
            log.debug( "-removeRow" );
        public void clearRow( int row )
            log.debug( "+clearRow(" + row + ")" );
            if( row < this.getDataRows().size() )
                GanttConstraint aConstraint = (GanttConstraint) this.getDataRows().get( row );
                aConstraint.setMasterId( null );
                aConstraint.setType( null );
                fireTableRowsUpdated( row, row );
            log.debug( "-clearRow" );
        public int getColumnCount()
            return getColumnNames().size();
        public int getRowCount()
            return dataRows.size();
         * The table will be filled with constraints relevant to 'clone'.
        private void buildDataVector()
            ArrayList  data = new ArrayList( 1 );
            Collection allConstraints = getClone().getStartConstraints();
            allConstraints.addAll( getClone().getEndConstraints() );
            Iterator constraintIter = allConstraints.iterator();
            while( constraintIter.hasNext() )
                GanttConstraint element = (GanttConstraint) constraintIter.next();
                if( element.getType().equals( GanttConstraint.START_SPECIFIED ) ||
                        element.getType().equals( GanttConstraint.FINISH_FROM_DURATION ) )
                    continue;
                else
                    data.add( element );
            this.setDataRows( data );
        private Vector getColumnNames()
            if( columnNames == null )
                columnNames = new Vector( 3 );
                columnNames.add( " " ); // Needs space otherwise all the headers disappear
                columnNames.add( "Task" );
                columnNames.add( "Constraint" );
            return columnNames;
        private void addPrimerRow()
            log.debug( "+addPrimerRow" );
            // Create a constraint for the 'clone' task. Set it as transient until validation
            // where we will deal with it if necessary.
            GanttConstraint primer = new GanttConstraint( real.getLookup() );
            primer.setObjectId( chart.getNextUniqueId() );
            primer.setTransient();
            primer.setSlave( getClone() );
            primer.setProject( getClone().getProject() );
            getClone().addConstraint( primer );
            this.getDataRows().add( primer );
            int lastRow = this.getRowCount() - 1;
            fireTableRowsInserted( lastRow, lastRow );
            log.debug( "-addPrimerRow" );

  • 4.0.1 crashes now when you double click a file to edit in source monitor

    If I double click a file to watch it in Media Browser or in the project window premiere crashes. In fact the only way I can open a source window to set in and out points is if the clip is in the timeline.
    This makes editing with premiere almost unusable. It tried it with a few different file types. At least I have AAF so I can take my projects back into CS3 till this gets fixed.

    My Vista 64 premiere install is all messed up. Adobe Media Encoder completely freezes. Probably OE but it was working fine yesterday. The only thing installed on my Vista 64 is Adobe CS4 and only editing related drivers are installed.
    My Vista 32 (on a seperate disk) is working fine with Premiere but Adobe Media Encoder doesn't want update.
    All messed up here. At least it's Friday.

  • I downloaded and installed Adobe reader.  The icon is in my Dock but when I double click I cannot open it,  Why?

    I downloaded and installed Adobe Reader 11 for Mac.  It appears in my dock but when I double click the icon it will not open.  Why?

    Hi Alian,
    Please try to follow the steps given in the article.
    http://helpx.adobe.com/creative-cloud/kb/sign-in-out-creative-cloud-desktop-app.html
    Regards,
    Sumit Singh

  • Can't double click on events to edit in iCal

    Hello,
    I upgraded to Lion the other day and am experiencing a problem in iCal.
    (1) When I click on an event to open or edit it, nothing happens. 
    (2) I also cannot add an event with a click either.  (Only with the "+" for the Quick Event tab).
    The top menu options (File/Edit/Calendar/View...) still work, so I can edit or add an event that way, but not by clicking on it.
    Is this a function of iCal in Lion or is something wrong?
    Thanks ahead of time for any help

    I had this same exact issue. Each time I double-clicked a song in iTunes, it would go into 'rename' mode instead of just playing the track. I finally found the cause and fixed the issue. In your System Preferences -> Trackpad settings, adjust your Double-click speed. If it is set high, lower it to the mid-range setting. After doing this, I was able to double-click track after track and they played as expected. In my case, it seems I had the double-click speed set too high and it just wasn't registering correctly. Hope this fixes your issue as well.

  • When I double click to start Firefox it comes up on screen then crashes. I have to double click again to open Firefox, why does this happen?

    <blockquote>Locking duplicate thread.<br>
    Please continue here: [/questions/766710]</blockquote><br>
    I have to double click on Firefox icon a secound time to start it. Why does Firefox go up on screen and then disapear? I do not get any crash report page.

    See:
    * http://kb.mozillazine.org/Browser_will_not_start_up
    * [[Firefox crashes when you open it]]

  • I must double click three times to log on to mozilla

    i must left click three times for mozilla to start up

    After two more updates this bug is gone. Problem solved.

  • Double click on cell in alv report

    Hi all,
    I want to show detail popup on cell of alv report. how to get the cell value.
    plz tell me the logic for getting cell value.
    thanks in advance.

    Hi,
    IF RS_SELFIELD-FIELDNAME = 'EBELN1'.
    * Read data table, using index of row user clicked on
    READ TABLE IT_EKKO INTO WA_EKKO INDEX RS_SELFIELD-TABINDEX.
    Please remember the field EBELN1 should be in IT_EKKO. after the read statement you can move which ever field you want to another for further processing
    like
    READ TABLE IT_EKKO INTO WA_EKKO INDEX RS_SELFIELD-TABINDEX.
    if sy-subrc eq 0.
      move it_ekkp-( your field name) to v_field
    endif.

  • Value of the previous cell when I double click a cell in ALV Grid.

    Hi !
    Suppose I have an internal table GT_ITAB and I use ALV Grid to print it on the screen. The colums are as below:
    Invoice No       Invoice Data        Customer No     Amount
      90001231        15.01.2009            100024             5
    Customer No Fields is Hot Spot and when I click it uses Call Transaction 'FD10N' and Skip First Screen.
    But the Problem is that :
    Callback subroutine that is defined for  "i_callback_user_command" receives the input and
    p_selfield type slis_selfield structure has the value by means of  p_selfield-value.
    Problem : How can I get also the value of Invoice Data Cell. I need "15.01.2009" to set the Year field of FD10n.
    I know that it is possible because SAP has examples of it.
    Please advice.
    Erkan VAROL.

    Hi ,
      In teh structure slis_selfield  there is a field tabindex , you can get the index of the record selected from this field and use this to read the internal table being displayed in the alv to get the entrired row.
    Regards
    Arun

  • Previous entered value is lost when double click in the Jtable cell.

    Hi,
    When I double click the cell in the Jtable, the pervious enter data is lost. I unable to mask the double click event also. Could you please help me out.
    Thanks in Advance,
    With Thanks and Regards,
    Shiva

    When I double click the cell in the Jtable, the pervious enter data is lost.No it isn't unless you've customized the code and made an error.
    If you need further help then you need to create a [Short, Self Contained, Compilable and Executable, Example Program (SSCCE)|http://homepage1.nifty.com/algafield/sscce.html], that demonstrates the incorrect behaviour.
    Don't forget to use the Code Formatting Tags so the posted code retains its original formatting. That is done by selecting the code and then clicking on the "Code" button above the question input area.

  • Double click does not edit cell

    One of my users: double-clicking a cell is expected to place the focus into the cell for editing, but the expected behavior isn't happening. Cursor remains unchanged.
    It's not the mouse; I tried a couple. It's not plist, deleted both.
    It is something totally simple but what?

    Complementary questions :
    (1) How is the app behaving if you run it in an other user account ?
    (2) Was Mac Os updated to 10.6.2 thru "Applications Update" ?
    If it was, it may be a good idea to apply the combo updater available from:
    http://support.apple.com/kb/dl959
    Yvan KOENIG (VALLAURIS, France) mercredi 24 mars 2010 16:17:34

  • Prevent jtable cell edit!!!!

    when i double click any cell in a table it gets editable. but i dont wish to do this. i want all the cells in the table non editable. so nobody can change the cell content. anyone tell me how to do this. thank you.

    Then search the forum for code that uses the isCellEditable(...) method to see examples.
    Or you could even read the JTable API of all things. Then follow the link to the Swing tutorial on "How to Use Tables" which also has an example of overriding the isCellEditable(...) method. The code in the tutorial overrides the method of the TableModel. I prefer to override the method in the JTable.

  • JTable cannot make cell non-editable

    I have create a JTable using the DefaultTablemodel. I want to make the cells non editable. I have overwritten the method isCellEditable with that shown below but when I double click any cell it still let me edit the cell. Someone please show me what is wrong.
    public boolean isCellEditable(int cellrow, int cellcol)
    return(false);
    // if (cellcol == 0)
    // return(false);
    // else
    // return(true);
    Regards
    pslloo

    Look at the tutorial! This sample works.
    Hope this help.
    import javax.swing.JTable;
    import javax.swing.table.AbstractTableModel;
    import javax.swing.JScrollPane;
    import javax.swing.JFrame;
    import javax.swing.SwingUtilities;
    import javax.swing.JOptionPane;
    import java.awt.*;
    import java.awt.event.*;
    public class TableDemo extends JFrame {
        private boolean DEBUG = true;
        public TableDemo() {
            super("TableDemo");
            MyTableModel myModel = new MyTableModel();
            JTable table = new JTable(myModel);
            table.setPreferredScrollableViewportSize(new Dimension(500, 70));
            //Create the scroll pane and add the table to it.
            JScrollPane scrollPane = new JScrollPane(table);
            //Add the scroll pane to this window.
            getContentPane().add(scrollPane, BorderLayout.CENTER);
            addWindowListener(new WindowAdapter() {
                public void windowClosing(WindowEvent e) {
                    System.exit(0);
        class MyTableModel extends AbstractTableModel {
            final String[] columnNames = {"First Name",
                                          "Last Name",
                                          "Sport",
                                          "# of Years",
                                          "Vegetarian",
                                          "essai"};
            final Object[][] data = {
                {"Mary", "Campione",
                 "Snowboarding", new Integer(5), new Boolean(false), new Integer(3)},
                {"Alison", "Huml",
                 "Rowing", new Integer(3), new Boolean(true), new Integer(3)},
                {"Kathy", "Walrath",
                 "Chasing toddlers", new Integer(2), new Boolean(false), new Integer(3)},
                {"Sharon", "Zakhour",
                 "Speed reading", new Integer(20), new Boolean(true), new Integer(3)},
                {"Angela", "Lih",
                 "Teaching high school", new Integer(4), new Boolean(false), new Integer(3)}
            public int getColumnCount() {
                return columnNames.length;
            public int getRowCount() {
                return data.length;
            public String getColumnName(int col) {
                return columnNames[col];
            public Object getValueAt(int row, int col) {
                return data[row][col];
             * JTable uses this method to determine the default renderer/
             * editor for each cell.  If we didn't implement this method,
             * then the last column would contain text ("true"/"false"),
             * rather than a check box.
            public Class getColumnClass(int c) {
                return getValueAt(0, c).getClass();
             * Don't need to implement this method unless your table's
             * editable.
            public boolean isCellEditable(int row, int col) {
                //Note that the data/cell address is constant,
                //no matter where the cell appears onscreen.
                if (col < 2) {
                    return false;
                } else {
                    return true;
             * Don't need to implement this method unless your table's
             * data can change.
            public void setValueAt(Object value, int row, int col) {
                if (DEBUG) {
                    System.out.println("Setting value at " + row + "," + col
                                       + " to " + value
                                       + " (an instance of "
                                       + value.getClass() + ")");
                if (data[0][col] instanceof Integer                       
                        && !(value instanceof Integer)) {                 
                    //With JFC/Swing 1.1 and JDK 1.2, we need to create   
                    //an Integer from the value; otherwise, the column    
                    //switches to contain Strings.  Starting with v 1.3,  
                    //the table automatically converts value to an Integer,
                    //so you only need the code in the 'else' part of this
                    //'if' block.                                         
                    //XXX: See TableEditDemo.java for a better solution!!!
                    try {
                        data[row][col] = new Integer(value.toString());
                        fireTableCellUpdated(row, col);
                    } catch (NumberFormatException e) {
                        JOptionPane.showMessageDialog(TableDemo.this,
                            "The \"" + getColumnName(col)
                            + "\" column accepts only integer values.");
                } else {
                    data[row][col] = value;
                    fireTableCellUpdated(row, col);
                if (DEBUG) {
                    System.out.println("New value of data:");
                    printDebugData();
            private void printDebugData() {
                int numRows = getRowCount();
                int numCols = getColumnCount();
                for (int i=0; i < numRows; i++) {
                    System.out.print("    row " + i + ":");
                    for (int j=0; j < numCols; j++) {
                        System.out.print("  " + data[i][j]);
                    System.out.println();
                System.out.println("--------------------------");
        public static void main(String[] args) {
            TableDemo frame = new TableDemo();
            frame.pack();
            frame.setVisible(true);
    [\code]                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                       

Maybe you are looking for

  • Share Photos on the same iMac with different user accounts... How do You???

    Hello, I was wondering if there is a way to share photos with another user (same computer, different log-in names) on the same iMac? There are two users on my iMac and I want to be able to share photos and other documents, music etc. with them, but c

  • Dynamic Header/Footer/Content in Portal

    Hi All i'm new to portal, i want that when user logs in according to user there should be Header , Footer and Content displayed dynamically. For example if User A is in department D then his department logo,footer along with contents related to his d

  • Why am I unable to select the boolean indicators on my front panel?

    Hello all, This has to be an easy one for you guys, but here goes... I created a front panel with approximately 20 boolean indicators on it (LEDs). I realized that I only had 10 functional, so I made the others 'greyed out and disabled'. Well, now th

  • Ad hoc query missing amounts

    Hi: I'm having problems in order to obtain amounts from a custom infotype, this custom infotype (9001) is attached to the positions. When I try to obtain information about amounts that I have store in the custom infotype with the ad hoc query, I have

  • Using Planning vs Essbase connection in financial reports

    What are the pros/cons of using an essbase connection for financial reporting vs using a planning connection? we are on 9.2.1. using the Financial reporting studio client. These are basic financial reports-cost center expense reports, income statemen