Jtable and reload of data

Hello, I've a JTable with some buttons in some columns.
First I create some data and a custom model with this data and the table with this model.
Then for the "special" buttons colums I use the getColumModel and setCellRenderer and setCellEditor to set the way of paint and a custom editor,finally i set up a mouse listener to the table.
Everything works but, when I delete one of the rows, I make new data[][] and get model of the table and use the method model.reload(data)
After updating the screen, the line with the deleted row dissapear, the table adjust his size automatically, everything works but there is a last blank line... and when I click where it was supposed to be the buttons (and there are no line here) the listener works (where there is no row) and obviusly an error appear.
The problems seem that model.reload(data) with the new data correctly repaint the table, but the last size is not deleted and there is a last blank row, and the listeners of this line are not removed from the model...
Any idea of what can I do?
Thanks in advance.

Read the AbstractTableModel API. Notice all the fireXXX methods. Somewhere in your custom TableModel you need to fire the appropriate event to tell the table that the model has changed and then it will repaint itself as required.

Similar Messages

  • After upgrading my iPhone to new 5.1 iOS, and reloading all of my files back in , my music appears to be in the phone, but when I press play, the music does not play, even though the pause button is now lit.

    After 6 hrs. Of upgrading to 5.1 iOS , and reloading all data my music will not play. The music was reloaded from iCloud, and shows up in library, but will not play.

    Basics from the manual are restrt, reset, restore.
    Have you tried each of these?

  • Non Cumulative Cube selective deletion and Reload

    Hi,
    We have a typical scenario, where in the company code displays # when we execute the inventory reports at plant level,
    Upon analysis, we did find the Plant to Company code mapping was not maintained at R/3. Now this was fixed, hence we are planning to do selective reload for that particular plant alone.
    Keeping in mind the loading sequence/scenarion for Inventory, can any one advise if we need to do stock init again for this plant and reload the data after selective deletion.
    Or can we directly load from the material movement datasource. Will there be any impact ie: at marker update etc.
    Note: We already have data into this inventory cube for last 2 years.
    The cube contain aggregate compression.
    Thanks
    Ramesh

    Any inputs please
    Ramesh

  • JScrollPanel, JTable, and a HorizontalScrollBars

    Am creating a JScrollPane, a JTable, and adding the table to the pane.
    I am also creating MyTableMode which extends AbstractTabelModel. MyTableModel provides the interface between the JTable and my particular data. I am able to display and edit the data, that interface is working fine.
    When I have more than about 10 rows of data, the vertical scroll bars appear. This is what I expect.
    But if there are more columns than can be seen in the viewport, the horizontal scroll bars do not appear. This is not what I expect.
    Example: if I create table with 72 rows by 72 columns, only rows 1-10 and columns 1-40 are visible (based on dialog size, preferred size, etc.). The vertical scroll bars are present, but the horizontal scroll bars are not. The user will not be able to scroll the viewport and see columns 41-72.
    I've read (and re-read) the "How to use Tables" and "How to use Scrollpanes", tutorials, and do not see anything obvious. Probably missed something. I did notice that none of the table examples have horizontal scrioll bars.
    Any suggestions?

    It's one of those days. Here is code with the imports:
    package components;
    * TableDemo.java requires no other files.
    import javax.swing.JFrame;
    import javax.swing.JPanel;
    import javax.swing.JScrollPane;
    import javax.swing.JTable;
    import javax.swing.table.AbstractTableModel;
    import java.awt.Dimension;
    import java.awt.GridLayout;
    * TableDemo is just like SimpleTableDemo, except that it
    * uses a custom TableModel.
    public class TableDemo extends JPanel {
        private boolean DEBUG = false;
        public TableDemo() {
            super(new GridLayout(1,0));
            JTable table = new JTable(new MyTableModel());
            table.setPreferredScrollableViewportSize(new Dimension(500, 70));
            table.setFillsViewportHeight(true);
            //Create the scroll pane and add the table to it.
            JScrollPane scrollPane = new JScrollPane(table);
            //Add the scroll pane to this panel.
            add(scrollPane);
        class MyTableModel extends AbstractTableModel {
            public int getColumnCount() {
                //return columnNames.length;
                return 72;
            public int getRowCount() {
                //return data.length;
                return 72;
            public String getColumnName(int col) {
                //return columnNames[col];
                return Integer.toString(col);
            public Object getValueAt(int row, int col) {
                //return data[row][col];
                return 0;
            public boolean isCellEditable(int row, int col) {
                return false;
         * Create the GUI and show it.  For thread safety,
         * this method should be invoked from the
         * event-dispatching thread.
        private static void createAndShowGUI() {
            //Create and set up the window.
            JFrame frame = new JFrame("TableDemo");
            frame.setDefaultCloseOperation(JFrame.EXIT_ON_CLOSE);
            //Create and set up the content pane.
            TableDemo newContentPane = new TableDemo();
            newContentPane.setOpaque(true); //content panes must be opaque
            frame.setContentPane(newContentPane);
            //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.
            javax.swing.SwingUtilities.invokeLater(new Runnable() {
                public void run() {
                    createAndShowGUI();
    }

  • Saving chart data and reload after restart of server?

    Hi
    I have a vi that communicate with another program called EES through DDE and sometimes EES mess up the server. My solution is to automatically restart the server once a day [this is good enough for me].
    My question is: How do I get all my data in my charts to save and reload easiest?

    Hi,
    I think you may create a database table in your server and then pass your data to this table every time a new entry is made and calling the same from the database every time you run the VI after its restart. This can easily be done using the database connectivity tool-kit in the function palette. 
    Regards,
    Nitz.
    (Kudos are always welcome)

  • One computer updated the other says up to date but they are the old version and reloading doesn't work.

    I updated to the latest version on my desktop, then my credit card was hack so it was replaced and I had to reset my credit card info. When I tried to update my laptop the CC App said all were up to date - but trying to load a file from the updated Premiere app from my desktop onto my laptop fails with a "Newer version" error message. I unloaded and reloaded premiere but that did not work.

    Alw51 what specific Newer Version error message are you referring too?  Also which operating system are you using?  Finally what version of Premiere Pro are you downloading and installing?

  • Timestamp when saved in text file and reloaded does not give correct dates

    Hello
    I am struggling with time stamp. I have almost corrected the problem but it is not as good as I expect it to be.
    I have data in the main vi which logs into text file with time stamp for everyday results logs.
    I then pull all this data to display on waveform graph with the performance data on y axis and time stamp on x axis.
    I convert the time stamp data from string back to time stamp using scan from function in string pallette. When I run the waveform graph vi. The time stamp data is not correct one. I see year values beginning 1974 etc. I change these values to 2011 and the correct dates and then could see the accurate logged data from data logger but I would like to have the starting date in my logged file the left most date on x-axis. I try modify dates in display format section of waveform graph but I think it gives the values in seconds which doesn't make much sense to me. Is it possible to automatically set the starting value of the graph as the first date in the logged file? I am new with using time stamps. Any feedback will be appreciated.
    Kind Regards
    Austin

    Hi Austin,
    "Is it possible to automatically set the starting value of the graph as the first date in the logged file?"
    Sure: Use autoscaling, format x-axis as time and use waveforms with correct t0 value...
    For all other questions you should attach a VI to show your current state of programming!
    Best regards,
    GerdW
    CLAD, using 2009SP1 + LV2011SP1 + LV2014SP1 on WinXP+Win7+cRIO
    Kudos are welcome

  • Refresh jTable after inserting new data into the Database

    Hey all,
    I'm using Netbeans 6.5 to create a Desktop Application which is connected to a Java DB (Derby).
    The first simple steps were all very successfull:
    Create the jTable and bind it to the Database => everything works fine. When the application starts it correctly shows all data from the database.
    The problem starts when I try to insert new data to the database.
    For that reason I've created textfields and a button "Save". When I press the button it successfully inserts the data to the database but they are not displayed in the jTable (when the application starts they are all there, they are not updated at runtime) . I've tried table.invalidate() and table.repaint() but they just don't work.
    Any help will be GREATLY appreciated. But please have in mind that most of the code is Netbeans-generated and most of it not editable.
    Many thanks in advance.
    George

    Once again you are right my friend. I jumped to conclusion way too fast, when I shouldn't. (Give me a break, I've been busting my head with this well over a week). The response I saw when I did that was that indeed a line is added to the jTable. Because I falsly set the index of the object to be added to be second to last the row appeared on the table, what I didn't see at the time was that the last one disappeared. Hmm...
    A new adventure begins...
    So after a few hours of messing around with it here are my observations:
    1) It was not an observable list. When I add the new element with employeesList.add(newEmp); , the table gets notified but a get a bunch of exceptions:
    xception in thread "AWT-EventQueue-0" java.lang.IndexOutOfBoundsException: Index: 84, Size: 84
            at java.util.ArrayList.RangeCheck(ArrayList.java:546)
            at java.util.ArrayList.get(ArrayList.java:321)
            at org.jdesktop.swingbinding.impl.ListBindingManager$ColumnDescriptionManager.validateBinding(ListBindingManager.java:191)
            at org.jdesktop.swingbinding.impl.ListBindingManager.valueAt(ListBindingManager.java:99)
            at org.jdesktop.swingbinding.JTableBinding$BindingTableModel.getValueAt(JTableBinding.java:713)
            at javax.swing.JTable.getValueAt(JTable.java:1903)
            at javax.swing.JTable.prepareRenderer(JTable.java:3911)
            at javax.swing.plaf.basic.BasicTableUI.paintCell(BasicTableUI.java:2072)
            at javax.swing.plaf.basic.BasicTableUI.paintCells(BasicTableUI.java:1974)
            at javax.swing.plaf.basic.BasicTableUI.paint(BasicTableUI.java:1897)
            at javax.swing.plaf.ComponentUI.update(ComponentUI.java:154)
            at javax.swing.JComponent.paintComponent(JComponent.java:743)
            at javax.swing.JComponent.paint(JComponent.java:1006)
            at javax.swing.JViewport.blitDoubleBuffered(JViewport.java:1602)
            at javax.swing.JViewport.windowBlitPaint(JViewport.java:1568)
            at javax.swing.JViewport.setViewPosition(JViewport.java:1098)
            at javax.swing.plaf.basic.BasicScrollPaneUI$Handler.vsbStateChanged(BasicScrollPaneUI.java:818)
            at javax.swing.plaf.basic.BasicScrollPaneUI$Handler.stateChanged(BasicScrollPaneUI.java:807)
            at javax.swing.DefaultBoundedRangeModel.fireStateChanged(DefaultBoundedRangeModel.java:348)
            at javax.swing.DefaultBoundedRangeModel.setRangeProperties(DefaultBoundedRangeModel.java:285)
            at javax.swing.DefaultBoundedRangeModel.setValue(DefaultBoundedRangeModel.java:151)
            at javax.swing.JScrollBar.setValue(JScrollBar.java:441)
            at javax.swing.plaf.basic.BasicScrollBarUI.scrollByUnits(BasicScrollBarUI.java:907)
            at javax.swing.plaf.basic.BasicScrollPaneUI$Handler.mouseWheelMoved(BasicScrollPaneUI.java:778)
            at javax.swing.plaf.basic.BasicScrollPaneUI$MouseWheelHandler.mouseWheelMoved(BasicScrollPaneUI.java:449)
            at apple.laf.CUIAquaScrollPane$XYMouseWheelHandler.mouseWheelMoved(CUIAquaScrollPane.java:38)
            at java.awt.Component.processMouseWheelEvent(Component.java:5690)
            at java.awt.Component.processEvent(Component.java:5374)
            at java.awt.Container.processEvent(Container.java:2010)
            at java.awt.Component.dispatchEventImpl(Component.java:4068)
            at java.awt.Container.dispatchEventImpl(Container.java:2068)
            at java.awt.Component.dispatchMouseWheelToAncestor(Component.java:4211)
            at java.awt.Component.dispatchEventImpl(Component.java:3955)
            at java.awt.Container.dispatchEventImpl(Container.java:2068)
            at java.awt.Component.dispatchEvent(Component.java:3903)
            at java.awt.LightweightDispatcher.retargetMouseEvent(Container.java:4256)
            at java.awt.LightweightDispatcher.processMouseEvent(Container.java:3965)
            at java.awt.LightweightDispatcher.dispatchEvent(Container.java:3866)
            at java.awt.Container.dispatchEventImpl(Container.java:2054)
            at java.awt.Window.dispatchEventImpl(Window.java:1801)
            at java.awt.Component.dispatchEvent(Component.java:3903)
            at java.awt.EventQueue.dispatchEvent(EventQueue.java:463)
            at java.awt.EventDispatchThread.pumpOneEventForHierarchy(EventDispatchThread.java:269)
            at java.awt.EventDispatchThread.pumpEventsForHierarchy(EventDispatchThread.java:190)
            at java.awt.EventDispatchThread.pumpEvents(EventDispatchThread.java:184)
            at java.awt.EventDispatchThread.pumpEvents(EventDispatchThread.java:176)
            at java.awt.EventDispatchThread.run(EventDispatchThread.java:110)
    Exception in thread "AWT-EventQueue-0" java.lang.IndexOutOfBoundsException: Index: 84, Size: 84
            at java.util.ArrayList.RangeCheck(ArrayList.java:546)
            at java.util.ArrayList.get(ArrayList.java:321)
            at org.jdesktop.swingbinding.impl.ListBindingManager$ColumnDescriptionManager.validateBinding(ListBindingManager.java:191)
            at org.jdesktop.swingbinding.impl.ListBindingManager.valueAt(ListBindingManager.java:99)
            at org.jdesktop.swingbinding.JTableBinding$BindingTableModel.getValueAt(JTableBinding.java:713)
            at javax.swing.JTable.getValueAt(JTable.java:1903)
            at javax.swing.JTable.prepareRenderer(JTable.java:3911)
            at javax.swing.plaf.basic.BasicTableUI.paintCell(BasicTableUI.java:2072)
    ... and a lot morewhich from my poor understanding means that the jTable succesfully notices the change but it is not able (??) to adjust to the new change. What is more interesting is that when I plainly add the element to the end of the list (without an idex that is), a blank row appears at the end of my Table. The weird thing is that I've bound the table to some text fields below it, and when I select that empty row all the data appear correctly to the text fields.
    I tried going through:
                    org.jdesktop.observablecollections.ObservableCollections.observableList(employeesList).add(newEmp);as well as
                    help = org.jdesktop.observablecollections.ObservableCollections.observableListHelper(employeesList);
                    help.getObservableList().add(newEmp);
                    help.fireElementChanged(employeesList.lastIndexOf(newEmp));and
                    obsemployeesList = org.jdesktop.observablecollections.ObservableCollections.observableList(employeesList);
                    obsemployeesList.add(newEmp);and I still get the same results (both the exeptions and the mysterious empty row at the end of the table
    So, I'm again in terrible need of your advice. I can't thank you enough for the effort you put into this.
    Best regards,
    George
    Edited by: tougeo on May 30, 2009 11:06 AM
    Edited by: tougeo on May 30, 2009 11:21 AM
    Edited by: tougeo on May 30, 2009 11:30 AM

  • JTable and clipboard...

    Hi all!
    I'm trying to copy data from JTable to system clipboard. Here's my code that is
    supposed to do that except it doesn't work. Nothing happens. The system is
    Windows, rigth click invokes menu with only one position - COPY, which is served
    by a appopriate ActionListener. I want to copy entire table (all data):
    private class NotEditableTable extends JTable
    NotEditableTable(Object[][] data, Object[] columnNames)
    super(data, columnNames);
    setAutoResizeMode(JTable.AUTO_RESIZE_OFF);
    setCellSelectionEnabled(true);
    getTableHeader().setReorderingAllowed(false);
    NotEditableTableEngine nete = new NotEditableTableEngine();
    this.addMouseListener(nete);
    public boolean isCellEditable(int row, int column)
    return false;
    private class NotEditableTableEngine extends MouseAdapter implements ActionListener
    public void mouseReleased(MouseEvent e)
    if (e.isPopupTrigger())
    JPopupMenu menu = new JPopupMenu();
    JMenuItem menuitem = new JMenuItem(Lang.TABLE_COPY, new ImageIcon("res/Copy16.gif"));
    menuitem.addActionListener(this);
    menu.add(menuitem);
    menu.show(NotEditableTable.this, e.getX(), e.getY());
    public void actionPerformed(ActionEvent e)
    TransferHandler th = new TransferHandler(null);
    NotEditableTable.this.setTransferHandler(th);
    Clipboard clip = NotEditableTable.this.getToolkit().getSystemClipboard();
    th.exportToClipboard(NotEditableTable.this, clip, TransferHandler.COPY);
    }

    I also tried the code above with a simple JTextField, both with text selected and not.Did my sample code use the TransferHandler??? The simple way to do it for a JTextField would be
    Clipboard c = Toolkit.getDefaultToolkit().getSystemClipboard();
    StringSelection testData = new StringSelection( textField.getText );
    //StringSelection testData = new StringSelection( textField.getSelectedText );
    c.setContents(testData, testData);
    As for the table I said that the Ctrl-C KeyStroke will invoke the default Action to copy selected data from the JTable to the Clipboard. This can be tested manually by simply using Ctrl-C. If you want to invoke it in your program then you need to get the corresponding Action from the JTable and invoke the ActionPerformed method of the Action. You can try using the
    getActionForKeyStroke(...) method of JComponent to get the Action.

  • How do I use icloud to restore my documents that were in Pages? Pages got stuck in "waiting" to update and when nothing else worked I deleted it and reloaded Pages. I don't want to restore everything just my Pages documents.

    How do I use icloud to restore my documents that were in Pages? Pages got stuck in "waiting" to update and when nothing else worked I deleted it and reloaded Pages. Everything I can find is about wiping everything out and restoring everything. I don't want to restore everything just my Pages documents (and numbers and keynote that also locked up during updating).

    What I meant is turn off Documents and Data in iCloud in OS X. Keep it on on your iOS devices. iCloud will sync documents between the iOS devices and make them available on the iCloud web site, but it won't mess up iWorks' open and save dialog boxes. It also won't assume that you want all your documents in iCloud, which I think is undesirable anyway.
    Keep iOS and OS X separate, and use the web site to move files between the two as necessary.
    iOS iWork is different from OS X iWork. There are fewer fonts on an iOS device. iOS iWork programs have slightly different feature sets than OS X iWork programs, and the file formats are different. iCloud automatically converts the file format when necessary, but if you make a habit of saving things directly to iCloud, you are limited to the lowest common denominator between the two versions of iWorks. So why would anyone want iWork on the Mac to open and save documents on iCloud by default?
    If you want to store files in the cloud and sync them on your Macs, SugarSync is a much better solution. It lets you choose your sync folders, it doesn't make you reorganize your files, it lets you sync all file types, it doesn't convert files to a different format and back, and it stores everything in the cloud, too. Just the simle act of saving a file backs it up and syncs it. I wouldn't live without it. iCloud is best with iTunes purchases and synchronizing Mac settings and iOS files; I woudln't live without it. The two make an unbeatable combination.

  • Time Machine Locked after MacBook Air reformatted. My MacBook Air was overfull due to an Address book issue (duplication) so after many attempts to clear space, I ended up wiping out the system and reloading Lion.

    Time Machine Locked after MacBook Air reformatted. My MacBook Air was overfull due to an Address book issue (duplication) so after many attempts to clear space, I ended up wiping out the system and reloading Lion. This resulted in the Time Machine thinking that it was now connected to a different computer. Apparently this diables the existing information. 
    Now I can see that the back-ups exist (back to Sept 2012) but they are greyed out, therefore unavailale to restore. Again, this seems like an issue that shouldn't be happening. The whole point of the Time Machine is to enable reinstatement of data after catastrophic failure. What if my computer actually had to be replaced due to a hardware issue? How would I beableto restore anything?
    The path already (unsuccessfully) taken;
    Open Library on the computer, Open Time Machine, Select Correct date, drill down to correct data you wish to restore, click "Restore".
    This did not work because the correct date was greyed out. Restore key was greyed out.

    Time Machine Locked after MacBook Air reformatted. My MacBook Air was overfull due to an Address book issue (duplication) so after many attempts to clear space, I ended up wiping out the system and reloading Lion. This resulted in the Time Machine thinking that it was now connected to a different computer. Apparently this diables the existing information. 
    Now I can see that the back-ups exist (back to Sept 2012) but they are greyed out, therefore unavailale to restore. Again, this seems like an issue that shouldn't be happening. The whole point of the Time Machine is to enable reinstatement of data after catastrophic failure. What if my computer actually had to be replaced due to a hardware issue? How would I beableto restore anything?
    The path already (unsuccessfully) taken;
    Open Library on the computer, Open Time Machine, Select Correct date, drill down to correct data you wish to restore, click "Restore".
    This did not work because the correct date was greyed out. Restore key was greyed out.

  • I need to erase the HDD and reload OSX on my new mac mini without a DVD

    I have purchased a Mac Mini and restored from a time machine backup, however I need to erase all the data so that I can give this computer to my son, how do I delete everything and reload OSX. Please I need some help. Thankyou

    erdmd wrote:
    ...I need to erase all the data so that I can give this computer to my son,...
    See Thomas Reed's How to Prepare your Mac for sale
    Also see Kappy’s comprehensive post here...
    https://discussions.apple.com/message/21565512?ac

  • Can't reload Bing app after wiping and reloading lastest AT&T OS 5

    Howdy all,
    Please forgive me if this has already been addressed and I just haven't found it yet.
    I was having all sorts of oddities with my BlackBerry Curve 8900 (AT&T carrier), so I backed up my data, wiped, and reloaded the latest OS from AT&T (5.0.0.1067).  Before wiping my device, I had both the Bing search and Bing map apps on my device.  I don't recall when I loaded them, but I'm sure I was running an iteration of OS 5, and not 4.x with an upgrade.
    Anyways, after wiping and reloading the OS, I can't load the Bing app to my Berry.  When I go to their website, and follow the mobile link, whether I type the provided URL in (http://m.bing.download), or I have their site send me a text message with a link to download (http:/m.bing.com/?mid=40012), I get the same message, as follows:
    "We were unable to detect your phone type or we do not offer support in your region.  To try Bing anyway, click here."
    I don't recall how, but somewhere in my interwebs searching, I found a link that took me right to the Bing app's location in AppWorld.  I followed this, but it also told me that the app was unavailable for the device.
    According to Microsoft's website, it is available for my model.  Of course, since I was actually using it on my Berry prior to wiping and reloading the OS, I'm not sure why it's unavailable now.  Is it possible that the Berry is being misidentified?  I was running 5.0.0.1067 prior to wiping and reloading, so it shouldn't be an OS version.  My Vendor ID shows as "2," so it should be seen with AT&T as my carrier (and, by default, in the US).
    It's not a big deal, but I prefer Bing maps and search, and can't figure out why I can't reload it.  I've already contacted Bing support at Microsoft, and they just provided me the same links, and told me to go ask BlackBerry support.  And please, don't respond with, "Just use Google."   I have and can use Google, but that's not why I'm posting.  It may be that I'm just out of luck, and won't be able to use Bing, but I figured I should ping out to the community first in case some of y'all had any ideas.
    Thanks in advance, and I appreciate any help y'all can give!
    Jeff

    I had exactly the same problem and was most disappointed at not being able to reinstall the Bing search application and Maps. I'm guessing you have found a solution by now but just in case and for the benefit of anyone else in this position I have a possible solution.
    It took a lot of searching but eventually I found a page which offered a download of the early (1st) release of the Bing application for various BlackBerry handsets not including mine. I did however manage to select and successfully download a version for a different device which installed ok. Upon opening the Bing app I immediatley received a pop up message informing me that there was a newer version of the application available, would I like to update ? I selected yes to update and hey presto, I once again had the latest and correct version of Bing search and Maps on my device.
    Here is the link http://handheld.softpedia.com/progDownload/Bing-Bl​ackBerry-Download-89065.html
    Any problem with the link then you are searching for "Bing (BlackBerry) 1.0: Free Download on the Softpedia Handheld site". Once there you will see a list of devices and download locations in the bottom right hand corner. Good luck and enjoy this great app. Hope RIM add it to Appworld on both sides of the Atlantic soon. Very useful and works perfectly on my Torch 9800.
    BlackBerry is for Life not just for Christmas

  • I had mozilla on my pc and it stopped working. I deleted and reloaded it. It won't open. Help!!!

    Have had this computer since June. Mozilla was downloaded and worked fine till about a month or so ago. It stopped working. I deleted the download and reloaded it three times. The download took but when I would click on the icon nothing would happen. I think I have windows 8. Is this the problem? Thanks for you help!
    B

    Some problems occurs when your Internet security program was set
    to trust the previous version of Firefox, but no longer recognizes your
    updated version as trusted. Now how to fix the problem: To allow
    Firefox to connect to the Internet again;
    * Make sure your Internet security software is up-to-date (i.e. you are running the latest version).
    * Remove Firefox from your program's list of trusted or recognized programs. For detailed instructions, see
    '''[https://support.mozilla.org/en-US/kb/configure-firewalls-so-firefox-can-access-internet Configure firewalls so that Firefox can access the Internet.]''' {web link}

  • JTable and ResultSet TableModel with big resultset

    Hi, I have a question about JTable and a ResultSet TableModel.
    I have to develop a swing JTable application that gets the data from a ResultSetTableModel where the user can update the jtable data.
    The problem is the following:
    the JTable have to contain the whole data of the source database table. Currently I have defined a
    a TYPE_SCROLL_SENSITIVE & CONCUR_UPDATABLE statement.
    The problem is that when I execute the query the whole ResultSet is "downloaded" on the client side application (my jtable) and I could receive (with big resultsets) an "out of memory error"...
    I have investigate about the possibility of load (in the client side) only a small subset of the resultset but with no luck. In the maling lists I see that the only way to load the resultset incrementally is to define a forward only resultset with autocommit off, and using setFetchSize(...). But this solution doesn't solve my problem because if the user scrolls the entire table, the whole resultset will be downloaded...
    In my opinion, there is only one solution:
    - create a small JTable "cache structure" and update the structure with "remote calls" to the server ...
    in other words I have to define on the server side a "servlet environment" that queries the database, creates the resultset and gives to the jtable only the data subsets that it needs... (alternatively I could define an RMI client/server distribuited applications...)
    This is my solution, somebody can help me?
    Are there others solutions for my problem?
    Thanks in advance,
    Stefano

    The database table currently is about 80000 rows but the next year will be 200000 and so on ...
    I know that excel has this limit but my JTable have to display more data than a simple excel work sheet.
    I explain in more detail my solution:
    whith a distribuited TableModel the whole tablemodel data are on the server side and not on the client (jtable).
    The local JTable TableModel gets the values from a local (limited, 1000rows for example) structure, and when the user scroll up and down the jtable the TableModel updates this structure...
    For example: initially the local JTable structure contains the rows from 0 to 1000;
    the user scroll down, when the cell 800 (for example) have to be displayed the method:
    getValueAt(800,...)
    is called.
    This method will update the table structure. Now, for example, the table structure will contain data for example from row 500 to row 1500 (the data from 0 to 499 are deleted)
    In this way the local table model dimension will be indipendent from the real database table dimension ...
    I hope that my solution is more clear now...
    under these conditions the only solutions that can work have to implement a local tablemodel with limited dimension...
    Another solution without servlet and rmi that I have found is the following:
    update the local limited tablemodel structure quering the database server with select .... limit ... offset
    but, the select ... limit ... offset is very dangerous when the offset is high because the database server have to do a sequential scan of all previuous records ...
    with servlet (or RMI) solution instead, the entire resultset is on the server and I have only to request the data from the current resultset from row N to row N+1000 without no queries...
    Thanks

Maybe you are looking for

  • Is there any way to restore deleted calendars back onto my laptop from my iPhone.

    I recently installed Maverick on my laptop and have been having trouble syncing my iphone calendars with my laptop calendars, like I used to. Like an idiot, and without any research, I joined iCloud thinking I could sync calendars this way. I didn't

  • No popup when using cl_bsp_utility= download

    Hi friends, I´m using cl_bsp_utility=>download method from my BSP to download a file. I´ve never used it, but as long as I could see in the forum, it´s suppossed to open a popup to choose the file destination, right?... Well, I´m getting nothing...wh

  • Time Machine locked disk

    Connected a WD My Book pro to my G5 PM running OS 10.5.1. After a few minutes into the first backup it failed the backup with the message: Time Machine Error - Unable to complete backup. An error occurred while creating the backup directory. Tried de

  • CRASHES, I wanna curse!

    I'm just curious to know if anyone is having similar problem as I am since the leopard. I can't be sure, maybe it's the new iMac with upgrade RAM I got. Even iTune crashes and never shuts off. Force quit does not work and when one of the application

  • Configuring airport express to work with a secure router

    i have installed a new router on our network and have added security.  My airport express no longer can recognize the network since I believe it has to pass along a password. How do I tell the airport express the network password?  Airport utility ve