JTable Won't Allow Editing Despite isCellUpdatable is Set to Return True

Mass apologies if I somehow sent this to the wrong forum by mistake. However, aid from the local Java gurus would be much appreciated since I'm the only Java programmer at this company, so I don't have anyone to really ask for advice or anything.
I've been trying to enter an updatable ResultSet into a JTable for about a week now, but the issue I ended up running into was that if you click on a cell with the intention to edit the contents, it won't even highlight the cell, much less let you edit it.
I've searched Google and this forum along with tried to hunt down more complex books on Java rather than your standard "So you want to learn Java" cookbooks, but I've come up with null. I've also created about five different variations of TableModels for the purposes of handling this, including one that used an array of Objects instead of the ResultSet, but the problem persists.
Here is the latest version of the TableModel that I've come up with
package EventCalGUI;
import javax.swing.table.AbstractTableModel;
import EventCalSQL.TableData;
@SuppressWarnings("serial")
public class UpdateRSModel extends AbstractTableModel
     /** <code>TableData</code> from database */
     private TableData data;
     public UpdateRSModel(TableData tdata)
          data = tdata;
     @Override
     public int getColumnCount()
          return data.getColCount();
     @Override
     public int getRowCount()
          return data.getRowCount();
     @Override
     public Object getValueAt(int row, int col)
          return data.getValue(row, col);
     @Override
     public boolean isCellEditable(int row, int col)
          return true;
     @SuppressWarnings("unchecked")
     @Override
     public Class getColumnClass(int col)
          return data.getColClass(col);
     @Override
     public String getColumnName(int col)
          return data.getHeader(col);
     @Override
     public void setValueAt(Object value, int row, int col)
          data.setValue(value, row, col);
}The reason for suppressing the warnings is because Eclipse attempts to be too helpful with its cautions and I was sick of seeing a long list of unnecessary yellow caution signs.
This is the TableData class that the above TableModel derives from. I hadn't added in the actual ResultSet updating capabilities until I was sure I could get the JTable to work.
package EventCalSQL;
import java.sql.*;
public class TableData
     Object[][] data = null;
     String[] headers = null;
     int rows = 0;
     int cols = 0;
     @SuppressWarnings("unchecked")
     Class[] colclass = null;
     public TableData (ResultSet rs)
          try
               ResultSetMetaData metadata = rs.getMetaData();
               // -------------- SET COLUMN DATA ---------------
               cols = metadata.getColumnCount();
               headers = new String[cols];
               colclass = new Class[cols];
               String classname = "";
               for (int b = 0; b < cols; b++)
                    headers[b] = metadata.getColumnName(b + 1);
                    classname = metadata.getColumnClassName(b + 1);
                    colclass[b] = Class.forName(classname);
               // ------------ SET ROW DATA --------------
               if (rs.last())
                    rows = rs.getRow();
                    rs.beforeFirst();
               if (rows != 0)
                    data = new Object[rows][cols];
                    for (int i = 0; i < rows; i++)
                         rs.absolute(i + 1);
                         for (int a = 0; a < cols; a++)
                              data[i][a] = rs.getObject(a + 1);
          catch (SQLException sql)
               // I'M UNINTERESTING!
          catch (ClassNotFoundException cnf)
               // BE BORED!
          catch (NullPointerException np)
               // I'M BORING!
     public Object getValue(int row, int col)
          return data[row][col];
     public String getHeader(int col)
          return headers[col];
     public void setValue(Object value, int row, int col)
          data[row][col] = value;
     public int getRowCount()
          return rows;
     public int getColCount()
          return cols;
     @SuppressWarnings("unchecked")
     public Class getColClass(int col)
          return colclass[col];
}I've checked the exceptions, and they work. I just added into the comments since nothing's really supposed to happen there if it's an empty set. I just have a weird sense of humor after twenty-plus hours of coding variations of the same thing over and over.
Thank you very much for any and all help ahead of time!

Hidralisk: Thank you for the suggestion, but that's not the problem I'm running into. I really appreciate you trying to help though.
camickr: I'll double-check my code to see where I might've unintentionally strayed from your suggestion. I deeply appreciate the help.
Edited by: wsizemore on Dec 6, 2007 6:51 AM
Haven't had the time to double-check my code since I've been re-assigned to other projects (the joys of being the solo Java programmer here), but I awarded you the points, camickr, since your suggestion seems to be the one that could've put me on the right track. Thanks so much for your help.

Similar Messages

  • Site with editable regions won't allow editing

    Hi, I have set up multple sites for InContext Editing. All works fine except this last one that won't allow editing online. When clicking "Edit Page" I get a message saying "There are no editable regions." I have checked and double checked the pages and the regions are there. I've reflowed the content into all pages (template) but I still get the same message in InContext.
    Please help me figure out what's wrong and how I can get the pages editable.
    Here's a link to the website http://www.nolimithockey.com
    Let me know if you need anything else in order to help me figure this out.
    Thanks a bunch!
    Hanna in Tahoe

    i'm done, thank you
    2009/10/19 Dan POPA <[email protected]>
    >
    InContext Editing can edit only the elements having the ice:editable
    attribute set.
    Your page should contain something like this:
    >
    <!-- the following DIV is an ICE editable region -->
    <div ice:editable="*">
       some editable content here
    </div>
    >
    But there are no such elements in the
    http://www.nolimithockey.com/index.html page.
    >
    You say you can see the ICE regions in that page so I can only assume that
    you didn't upload the file on the FTP server and you are looking at your
    local version of the file, not the one from the server.
    >
    Another possibility is that you mistakenly treat Dreamweaver Template
    Editable Regions as InContext Editable Editable Regions.
    I  can see that there are DW editable regions in your page: the elements
    located between the <!-- InstanceBeginEditable name="Headline" > and <!
    InstanceEndEditable --> comments.
    >
    >
    You can create ICE editable regions by selecting in Dreamweaver an element
    and applying the Create Editable Region command under the DW menbu Insert ->
    InContext Editing menu, see the image:
    >
    http://forums.adobe.com/servlet/JiveServlet/download/2242-505554-2323206-23866/create_ice_ er.png
    >
    Please let me know if any of these were of any help to you,
    Regards,
    Dan Popa
    >

  • I have a 3G iphone4, iOS 5.1.1. I changed my apple ID and since then iCloud has constantly helpfully let me know that my user name or password is incorrect. I have edited my password in my iCloud account settings, but it won't allow editing my user name

    Recently changed my apple ID. On my 3G iPhone 4 iCloud has since then been letting me know that my user name or password is incorrect.  I can edit the password in iCloud account information but user name is grayed out and can't be changed to my new apple ID. Haven't been be able to fix this by going into my Apple ID account or synching the iPhone.

    In order to change your Apple ID or password for your iCloud account on your iOS device, you need to delete the account from your iOS device first, then add it back using your updated details. (Settings > iCloud, scroll down and hit "Delete Account")
    Providing you are simply updating your existing details and not changing to another account, when you delete your account, all the data that is synced with iCloud will also be deleted from the device (but not from iCloud), but will be synced back to your device when you login again.

  • Address book won't allow edit

    I can't edit any address in my address book. I can't back up or add new contacts. I have alot of my contacts in Smart groups.

    Hi, any progress on this yet?
    BTW Smart Groups are just Alias list of the Main AB DB.

  • New Stationery won't allow edits

    We've created new stationery (actually modified existing stationery to create a new one) and placed it in the correct folder structure in /library/ to get it to show up in Mail app in the Stationery list. However, when we create a new message and click on this Stationery, we find that we cannot edit the text in the message. I imagine that, everytime we wanted to use the stationery, we could probably 1) change the text in the content.html file, 2) place that file back into the .mailstationery directory, and 3) restart Mail, but that seems a little barbaric.
    Is there something we can change to make our stationery editable from within Mail? I can send the .mailstationery files if that would be helpful.
    Thanks!

    Just posted this quickie hack for same problem:
    http://discussions.apple.com/messageview.jspa?messageID=8514000&stqc=true

  • Ipad won't allow editting of a website

    I am the webmaster of two websites.  However, since one of the recent updates, I have not been able to edit the websites from the ipad. 
    Can anyone help me out?

    Then you mean you are using an online form, not actually editing the website?  You might try the corresponding app from the app store: https://itunes.apple.com/us/app/sport-ngin/id499597400?mt=8

  • Lightroom won't allow me to edit the middle square of my image

    For some reason lightroom currently won't allow me to make any changes to the middle square of my image but I can do anything i want to any other parts of the image. Any ideas what is going on?

    it says the old one can't be deleted
    Assuming here that the message goes on to say "contact your technical support group".
    (1) Download the Windows Installer CleanUp utility installer file (msicuu2.exe) from the following Major Geeks page (use one of the links under the "DOWNLOAD LOCATIONS" thingy on the Major Geeks page):
    http://majorgeeks.com/download.php?det=4459
    (2) Doubleclick the msicuu2.exe file and follow the prompts to install the Windows Installer CleanUp utility. (If you're on a Windows Vista or Windows 7 system and you get a Code 800A0046 error message when doubleclicking the msicuu2.exe file, try instead right-clicking on the msicuu2.exe file and selecting "Run as administrator".)
    (3) In your Start menu click All Programs and then click Windows Install Clean Up. The Windows Installer CleanUp utility window appears, listing software that is currently installed on your computer.
    (4) In the list of programs that appears in CleanUp, select any iTunes entries and click "Remove", as per the following screenshot:
    (5) Quit out of CleanUp, restart the PC and try another iTunes install. Does it go through properly this time?
    Message was edited by: b noir

  • HT3728 My Time Capsule won't allow me to access my home network each day (intermittently) between about 1000-1800. My modem is working properly, and I can get on-line by hooking my computer straight to my modem, so I know it's the Time Capsule at fault. I

    My Time Capsule won't allow me to access my home wireless network for several hours each day -- usually between 1000-1830 or so. My modem is working correctly and I can still get on-line by going straight from my computer (MacBook Pro) to the Ethernet port. It must be the Time Capsule -- any ideas?

    Any ideas?
    Wireless Interference
    Might be caused by a cordless phone in the vicinity. To give you an example, my neighbor.....across the street...used to be able to literally crash my wireless network if he was in his front yard talking on his cordless phone.
    I discovered this by accident one day after spending weeks trying figure out why my network would crash at random times.
    Other possibilities include a wireless security/camera system near you
    Still other things might be an amateur ham radio operator....which should not interfere....but again from experience, I know that this can occur.
    Yet another possibility is another wireless network near you that is being turned on and off at random times. Some users power up their modem/router only when they want to do so and leave it off otherwise.
    Some general rules to help avoid interference:
    Move any cordless phones that you might have as far away as possible from the Time Capsule and/or your computer(s)
    Avoid placing other electronic devices....computer, television, amplifier, satellite receiver, etc. near the Time Capsule and/or your computer(s)
    Avoid metal surfaces near the Time Capsule and/or your computers
    Elevate the Time Capsule as much as possible. Think of it as a water sprinkler....you want to get the room as wet as possible
    Experiment with different wireless channels on the Time Capsule. To do this:
    Open AirPort Utility
    Click on the Time Capsule
    Click Edit
    Click the Wireless tab
    Click Wireless Options
    Start with Channel 11 on the 2.4 GHz band and work your way down
    It is unlikely that you are picking up interference on the 5 GHz band since there are.....for now at least.....far fewer networks using this frequency.

  • How can i change my account id/email on my iphone for icloud??  it won't allow me to update it

    how can i change my account id/email on my iphone for icloud??  it won't allow me to update it despite that it already has been updated online through both itunes and icloud.  HELP!!

    In order to change your Apple ID or password for your iCloud account on your iOS device, you need to delete the account from your iOS device first, then add it back using your updated details. (Settings > iCloud, scroll down and hit "Delete Account")
    In order to change your Apple ID or password for your iTunes account on your iOS device, you need to sign out from your iOS device first, then sign back in using your updated details. (Settings > store, scroll down and tap your ID)

  • New itunes is destroying my life. It won't allow me to search. As soon as I type a single key in the search field. It freezes, then crashes. WHY??????

    It won't allow me to search. As soon as I type a single key in the search field. It freezes, then crashes. WHY??????

    Launch the Console application in any of the following ways:
    ☞ Enter the first few letters of its name into a Spotlight search. Select it in the results (it should be at the top.)
    ☞ In the Finder, select Go ▹ Utilities from the menu bar, or press the key combination shift-command-U. The application is in the folder that opens.
    ☞ Open LaunchPad. Click Utilities, then Console in the icon grid.
    Step 1
    Make sure the title of the Console window is All Messages. If it isn't, select All Messages from the SYSTEM LOG QUERIES menu on the left.
    Enter the name of the crashed application or process in the Filter text field. Post the messages from the time of the last crash, if any — the text, please, not a screenshot. 
    When posting a log extract, be selective. In most cases, a few dozen lines are more than enough.
    Please do not indiscriminately dump thousands of lines from the log into a message.
    Important: Some private information, such as your name, may appear in the log. Edit it out by search-and-replace in a text editor before posting.
    Step 2
    Still in the Console window, look under User Diagnostic Reports for crash reports related to the process. The report name starts with the name of the crashed process, and ends with ".crash". Select the most recent report and post the entire contents — again, the text, not a screenshot. In the interest of privacy, I suggest that, before posting, you edit out the “Anonymous UUID,” a long string of letters, numbers, and dashes in the header of the report, if it’s present (it may not be.) Please don’t post shutdownStall, spin, or hang logs — they're very long and not helpful.

  • TS3899 My email on my iPhone won't allow me to trash old messages -- I get "unable to move message" "message could not be moved to the mailbox Trash"  I have restored to factory settings, asked AT&T about it (no help).

    my iphone won't allow me to trash old email messages -- I get the little window that says "Unable to Move Message -- The message could not be moved to the mailbox Trash." AT&T can't help me -- no one else has this problem, even though we're all on the same server from my company. I have restored to factory settings, but it didn't help. My email account settings are correct, the same as on my computers, and I can trash old messages on them.
    What do I do now?

    I have had a similar problem recently and followed advice here. Specifically, I used the brute force approach. As suggested by this site, I strongly urge you to backup your mailbox before trying this fix - just to be on the safe side.
    Message was edited by: Rich JG

  • My iPhone 4S has stuck some how. It won't allow me yo swipe but tells me which button I am pressing! How do I get out of this, tried the usual, on off and holding both to reset but still stuck

    My iPhone 4S has stuck and won't allow me to swipe it open! It talks to me and tells me which button I'm pressing, tried to reset ect but not working,

    Sounds like you've switched on something under accessibility, I have an iPhone 5s & there it's under settings>General>accessibility.
    To swipe you could try using two fingers.
    Hth,
    Message was edited by: Doctor9fan

  • Photoshop cs6 won't allow me to highlight my existing text layers. Does anyone have experience with this problem?

    Photoshop cs6 won't allow me to highlight my existing text layers. I select the text tool and the text layer I want to edit, hover over text and each time I attempto to edit a new layer is created. Does anyone have experience with this problem?

    Be sure you go to Adobe's Web Site and make sure there are no Updates for CS6
    http://www.adobe.com
    Remember if you have trouble with a software issue it is the software and not caused by the Mac you are using
    Many users simply don't remember when you upgrade software you normally have to go to 3rd party web sites and update software as well.
    Cheers
    Don

  • "Could not save as 'filename' because of a program error."  Won't allow me to save in ANY format!

    I have a large file (3500x8300px) that i have been working on in Photoshop CS4 and i tried to save it after working on it for about 30 minutes and got the following message: "Could not save as 'filename' because of a program error."  I tried saving it as .psd, .pdf, .tif, even .jpg and received the same message each time.  I closed down all other software to ensure that there was enough memory available but to no avail.  I then just closed my MBP and waited until the next day hoping it was just a glitch and might work later on.  I opened it up the next day (forgetting about the save issue) and worked on the file for a few more hours and then tried saving it again. (that's when i remembered the issue...too late...the work was already done).  Nope...still won't let me save it.  I'm afraid i'll have to restart the program but cannot afford to lose this work.  Any thoughts on how to fix it?
    *note: i tried 'save for web' and it allowed me to save it as a flattened image (although rather slow due to filesize) but i need it in a layered format.
    ANY HELP would be much appreciated!
    Thanks.
    **(I'm running PS CS4 v. 11.0.2 on a MBP 2.8 GHz Intel Core 2 Duo with 4GB 1067 MHz DDR3 and have Lion OS X 10.7.2.)

    There's a long-standing issue in which Windows 7 Explorer sometimes gloms onto image files in the process of caching thumbnails in Thumbs.db files.  Thing is, Windows 7 itself no longer uses these files, because a new thumbnail caching subsystem has been implemented that uses a central database, but the Thumbs.db creation has been maintained by default for compatibility.  The good news is that you can turn it off via the Local System Policy editor, to get some relief from file access conflicts.
    Do you have Windows 7?
    If ao, and you have no legacy apps that need Thumbs.db files, you can do this:
    Click Start, type gpedit.msc into the search box, and hit Enter.
    When the Local Group Policy Editor comes up, navigate into:
    > User Configuration
    > Administrative Templates
    > Windows Components
    > Windows Explorer
    Right-click the entry Turn off the caching of thumbnails in hidden thumbs.db files and choose Edit.
    Enable the setting.
    Log off Windows and back on.
    -Noel

  • Acrobat Pro won't allow to save with Reader Extended Features

    I've saved forms this way before because all the users of our forms only have the free Reader version. For some reason it now won't allow me to save with the extended features. When I save as and hover over "Reader Extended PDF" it shows my 3 options but none of them are clickable. I don't know why it has saved before, but it won't now.
    I also have a secondary issue. A form I previously, successfully saved this way is now not working for one of the users. It won't allow her to save the information she inputs. To my knowledge it has not been changed and it has only been used by a few people. Why would it suddenly stop allowing her to save?
    I am working on a Mac, but the users are all on PC's. I've never had this be an issue before though.

    Be sure you're not in form editing mode when you attempt to enable the document.
    Regarding not being able to save with Reader after initially being able to, this has been reported before many times but the casue is often elusive. The document has somehow changed in a way that prevents the usage rights from being validated. This is not supposed to happen, but it does.

Maybe you are looking for

  • How to access a JSON structure key that starts with a number

    I've got an odd issue here.  I'm accessing someone else's JSON structure so I am not able to change it.  The JSON structure keys are named with both characters and numbers like this: 0 198456 product_id 198456 1 Rashaan Houston feat Tony Loreto artis

  • Your customer care department

    I think ur customer care department and the delivery for attending the problem is just horrible. only if u try getting in touch with the customer care department u will come to know that it is very difficult to get across the right person to take car

  • How to create new event in new hard drive

    i brought new mac n im doing editing in fcp x since 2 weeks, so i have only 1 tera hard driveand its almost full. now i need to do lot more. so im thinking to have extra hard drive. n my qestion is that can i use any hard drive or i need to have only

  • Ale model view problem

    Hi All, I am trying to transfer one material using MATMAS. I follow the following steps for ALE. 1) create logical systems in client 500 (sys500) & 600     (sys600) clients  in same server. 2) assign the logical systems to respective clients. 4)  cre

  • Create a empty node in target structure

    Hi,   The scenerio is idoc(HRMD_A07) to file   my target structure is   <Record>     <Record1>       field 1       field 2       field 3    <Record1/>    <Record2>       field 5       field 6    <Record2/>     <Record3>       field 7    <Record3/> <R