Tab and Key Listener

I have put a key listener in a JTextField, but when I hit the tab key it does not generate a keyPressed event. Currently tab does nothing not even cycle through GUI components. Can you help me figure ouy how to get it to recognize the tab key.
P.S. The code that is inside the tab block works as I tried it with other keys so that is not the error.

I would search the forums for jtextfield and tab in the title
http://search.java.sun.com/search/java/index.jsp?qp=&nh=10&qt=%2Btitle%3Ajtextfield+%2Btitle%3Atab&col=javaforums

Similar Messages

  • JTable TAB key listener

    Hi all:
    I'm trying to write a filterable jtable. User can input the filter rule in the table header and the table displays the filtered data at the same time when the user inputs letters. The table filter works fine. But when I try to add "TAB" key listener, I find that I can't track the "TAB" key. I use a customerized cell renderer to display the filterable table header, a customerized cell editor to edit the filterable table header. The cell editor is created like this:
    JTextField textField = new JTextField("");
    DefaultCellEditor cellEditor = new DefaultCellEditor(textField);
    And I add a KeyListener to the textField. The KeyListener can track other keys like "Shift", "Alt", "Ctrl", but it can't track "TAB". It's weird. I also add the KeyListener to JTableHeader, JTable, but when I edit something in the JTextField, I still can't catch the "TAB" key. Have any ideas? Thank you for your time.

    by default the Tab is used (and consumed) by
    focusManager to move focus between components. If you
    want to get it in a component you have to signal the
    manager to keep it's hands off. How to do so depends
    on the jdk version. Focus handling changed
    considerably between 1.3 and 1.4: Prior to 1.4 you
    have to subclass the component in question to return
    true on isManagingFocus(), since 1.4 you have to set
    the comp's focusTraversalKeys to make the manager take
    those instead of the default keys.
    Greetings
    JeanetteThanks Jeanette, it works. I use the Component.setFocusTraversalKeysEnabled(false) to disable all traversal keys of JTextField and add a KeyEventDispatcher to the KeyboardFocusManager. It finally works. Users can use "TAB" keyStroke and "Shift-TAB" keyStroke to traverse in the filterable table header now. Thank you for your great help and the $$ are yours.

  • How to use the validation work in Both TAB and Mouse keys in Forms6i

    Hi,
    I have a validation script once it's validated it should execute the query.But using When-Validate-Item i can't use execute_query.I am able to use the validation in Key-Next-Item trigger but if the user moves the cursor using mouse then it's not working.
    How to use the validation script working in Both Scenarios(Tab and Mouse keys).
    Can anyone please give inputs to rectify the above issue?.

    So you have multiple fields, but on at least one of them if it's valid you immediately want to execute the query?
    You could create a hidden field in a control block Query_Now default 'N'. In a WHEN-VALIDATE-ITEM on your item, if it's determined to be valid, then set Query_Now to 'Y'.
    In a WHEN-NEW-ITEM-INSTANCE at block level, check if Query_Now is 'Y'. If it is then execute the query (and set it back to 'N').

  • HT1689 On the new version of  iTunes the shuffle button and replay buttons appear to have disappeared on the genius tab and am always having to listen to shuffled songs now :( how can I stop this?

    On the new version of  iTunes the shuffle button and replay buttons appear to have disappeared on the genius tab and am always having to listen to shuffled songs now :( how can I stop this?

    It appears from many other posts that the " Keep This iPod in the Source List" function isn't included in iTunes 7 unfortunately. You can leave your feedback on it's absence at this link: Apple Product Feedback
    You can check out a workaround at this link which may help out for now: Create ready-to-sync playlists for Shuffles in iTunes 7

  • How to override traversal keys CTL-TAB and CTL-SHIFT-TAB in JSplitpane?

    Recently added a JSplitpane to a frame with a number of other panels. One of those panels has two actions triggered by CTL-TAB and CTL-SHIFT-TAB. Since adding the JSplitpane those actions no longer trigger, apparently because JSplitPane is ManagingFocusForwardTraversalKeys and ManagingFocustBackwardTraversalKeys.
    I found if I disable the splitpane that the original actions are triggered, but that disables the divider.
    What would be the recommended way to change the behavior of a JSplitpane to ignore CTL-TAB and CTL-SHIFT-TAB?
    This is a list of things I have tried:
    bodySplitPane.getInputMap().remove(KeyStroke.getKeyStroke(KeyEvent.VK_TAB, InputEvent.CTRL_MASK));
    bodySplitPane.getInputMap().remove(KeyStroke.getKeyStroke(KeyEvent.VK_TAB, InputEvent.CTRL_MASK | InputEvent.SHIFT_MASK));
    bodySplitPane.getActionMap().remove("focusOutForward");
    bodySplitPane.getActionMap().remove("focusOutBackward");
    bodySplitPane.setFocusTraversalKeysEnabled(false); // doesn't work
    bodySplitPane.setFocusTraversalKeys(0,new HashSet<KeyStroke>());
    bodySplitPane.setFocusTraversalKeys(1,new HashSet<KeyStroke>());
    bodySplitPane.enableInputMethods(false);
    //bodySplitPane.setEnabled(false); // false allows ctl-tab to pass through but freezes the divider so it can't be moved via mouseThanks in advance.
    Jeff
    Edited by: 837741 on Dec 6, 2012 1:11 PM
    Edited by: 837741 on Dec 6, 2012 1:13 PM

    Found this in the tutorial (http://docs.oracle.com/javase/tutorial/uiswing/misc/keybinding.html) which solved the problem for me:
    bodySplitPane.getInputMap(JComponent.WHEN_ANCESTOR_OF_FOCUSED_COMPONENT).put(KeyStroke.getKeyStroke(KeyEvent.VK_TAB, InputEvent.CTRL_MASK),"none");
    bodySplitPane.getInputMap(JComponent.WHEN_ANCESTOR_OF_FOCUSED_COMPONENT).put(KeyStroke.getKeyStroke(KeyEvent.VK_TAB, InputEvent.CTRL_MASK | InputEvent.SHIFT_MASK),"none");Turns out my left splitpane has no focusable components, but might be that if it did I would have needed to set the action in the other two input maps as well like this:
    bodySplitPane.getInputMap(JComponent.WHEN_IN_FOCUSED_WINDOW).put(KeyStroke.getKeyStroke(KeyEvent.VK_TAB, InputEvent.CTRL_MASK),"none");
    bodySplitPane.getInputMap(JComponent.WHEN_IN_FOCUSED_WINDOW).put(KeyStroke.getKeyStroke(KeyEvent.VK_TAB, InputEvent.CTRL_MASK | InputEvent.SHIFT_MASK),"none");
    bodySplitPane.getInputMap(JComponent.WHEN_FOCUSED).put(KeyStroke.getKeyStroke(KeyEvent.VK_TAB, InputEvent.CTRL_MASK),"none");
    bodySplitPane.getInputMap(JComponent.WHEN_FOCUSED).put(KeyStroke.getKeyStroke(KeyEvent.VK_TAB, InputEvent.CTRL_MASK | InputEvent.SHIFT_MASK),"none"); Contrary to what the tutorial says, "none" seems to work as the action for any of the input maps, and "nil" or any string seems to work. I found no need to define an action class as the tutorial states and the tutorial does not show any use of the action inner class.
    Also found this helpful http://www.ibm.com/developerworks/java/jdk/additional/IBM50KeyBindings.html
    Edited by: 837741 on Dec 7, 2012 7:25 AM

  • Navigate previous record,next record by entering key-up and key-down

    Hi ,
    JDeveloper11g_
    I am trying to solve of how to navigate previous record,next record by entering key-up and key-down in ADF Table.
    If any of you have this solution by JScript of Backing Bean please help me.
    Thanks
    zakir
    ===

    Hi zakir,
    I hope I understood your requirements correctly. You have an editable ADF table. You would like to use the up/down arrow keys to move from one row to the next/prev row of the same column. Since the Tab key moves the cursor to the right and Shift+Tab moves it to the left, now you want to implement the same thing but just up and down, correct? If so, try this.
    /** Javascript **/
    function detectKey(evt) {
        var inputText = evt.getSource();
        var id = inputText.getClientId();
        var start2 = id.indexOf(":") + 1;
        var end2 = id.lastIndexOf(":");
        var numValue = parseInt(id.substring(start2, end2));
        var evt2 = evt.getNativeEvent();
        arrows=((evt2.which)||(evt2.keyCode));
        switch(arrows) {
            // Up arrow
            case 38:
            numValue = numValue - 1;
            break;
            // Down arrow
            case 40:
            numValue = numValue + 1;
            break;
        var newStr = id.replace(/:\d:/, ':' + numValue + ':');
        var comp = AdfPage.PAGE.findComponent(newStr);
        if (comp != undefined) {
            comp.focus();
    /** Jspx. (Place a client listener on each inputText in the ADF table) **/
    <af:column .....>
      <af:inputText value="#{row.bindings.price.inputValue}" .....>
        <af:clientListener type="keyDown" method="detectKey"/>
      </af:inputText>
    </af:column>With this, you get to move Up/Right/Down/Left in the editable ADF table without using the mouse.
    References:
    http://thepeninsulasedge.com/blog/?cat=29
    af:clientListener attributes and methodes of event object in java script
    Regards,
    Chan Kelwin

  • HT1339 My ipod classic fails the sync test on Windows 7. help say go to summary tab and check for updates. I cannot find a summary tab

    My ipod is failing the sync diagnostic on my Windows 7. The troubleshooting guide say go to the Summary Tab and "check for updates" I can't find a summary tab. I have no problem sync with windows vista.

    chicx wrote:
    This is the third time of writing this on your Apple Support Communities!
    Not with your current user id.
    Far too much uneccesary information in your post, which only confuses things, a vast amount!
    Let's start with iTunes.
    Have you updated iTunes to 11.1.5, because the previous version did appear to have an issue about seeing iPods?
    With iTunes 11.1.5 installed, look in Edit/Preferences/Devices, (or use the ALT key, followed by the E key and then the F key) and make sure that the box named Prevent iPods, iPhones and iPads from syncing automatically does not have a tick in the box.
    Once you have doen those two things, check to see if the iPod is seen by iTunes.
    chicx wrote:
    By the way, what does IOS mean? (I thought IO stood for operating system, but am flummoxed by the S on the end.
    Really?
    OS stands for Operating System. (In computer speak, IO means Input/Output.)
    iOS originally stood for iPhone Operating System, but it now refers to the iPod Touch and iPhone. The iPod Classic, which you have listed in your profile as your iPod, does not use iOS.
    I assume that you have been listening to the Podcast in your iTunes on the computer as you cannot transfer it to your iPod. It's what I'd do.

  • I want Firefox to open to my homepage every time after it crashes. I do not want it to return to the tabs and applications that caused the crash. I am willing to lose information. How do I do this?

    Firefox crashes or seizes up when there are too many tabs and applications open, and causes my computer to crash or seize up. I use task manager to close Firefox or I restart my computer. Then, when Firefox restarts again, it automatically re-opens all the tabs and applications that caused the computer to seize or crash in first place. This is a waste of my time. I want Firefox to reopen to my homepage even if it crashes. I am willing to lose information to have Firefox reopen to a low-memory homepage. How do I do this?

    Set the Integer pref browser.sessionstore.max_resumed_crashes to 0 on the about:config page to get the about:sessionrestore page immediately with the first restart after a crash has occurred or the Task Manager was used to close Firefox.
    * http://kb.mozillazine.org/browser.sessionstore.max_resumed_crashes
    That will allow you to deselect the tab(s) that you do not want to reopen, but will allow to reopen other tabs.
    See:
    * http://kb.mozillazine.org/Session_Restore#Restoring_a_session_after_a_crash
    * http://kb.mozillazine.org/Browser.sessionstore.max_resumed_crashes
    See also:
    * https://wiki.mozilla.org/Session_Restore#Preferences
    To open the <i>about:config</i> page, type <b>about:config</b> in the location (address) bar and press the "<i>Enter</i>" key, just like you type the url of a website to open a website.<br />
    If you see a warning then you can confirm that you want to access that page.<br />
    *Use the Filter bar at to top of the about:config page to locate a preference more easily.
    *Preferences that have been modified show as bold (user set).
    *Preferences can be reset to the default via the right-click context menu if they are user set
    *Preferences can be changed via the right-click context menu: Modify (String or Integer) or Toggle (Boolean)

  • PM Order, cost and key figures

    I have created and configured a new PM planning plant, cost center, work center, pm types and all that usual of PM requirement, but still I think something is missing in in the ingredient because when I try to creat a PM order and assign a bunch of operations with man hours to it, I discovered that there is NO cost and key figures showing...basically the estimated cost show $0.00. In other Plant it shows correct est cost.
    Any help will greatly appreciate with rewarding points.
    Thanks,
    Tim

    COst in order operations will get summarised under cost tab as labour/internal cost provided-
    1.Activity rate is maintained for activity via KP26 for cost centre
    2.Cost center is entered into work centre master data.
    3.Value category maintained correctly for cost element group where cost elemnt for internal cost is within this group.
    In your case it seems missing link is activity rate maintenace.
    Thanks
    Atul

  • What happened to my tabs and tab groups when I synced to a new computer?

    I have spent the morning trying to sync Firefox. On my previous computer, I was running FF31, but not as a clean install--as an upgrade from FF28. In the Sync screen, I saw my email address and recovery key, so I thought I was good to go.
    Turns out that that wasn't the case, and I needed to set up a new Sync account.
    Here are the steps I took to get my data back:
    1) I uninstalled FF31, reverted to 28, used my email address and recovery key, and got my information back.
    2) Then I updated to FF31.
    3) In FF31, I unlinked my computer, created a new Sync account, and logged in to sync my data.
    However, I was unable to access my tab groups. And when I upgraded to FF31, my tab groups still weren't back.
    I tried looking in "Tabs from Other Devices", and there were no other devices listed.
    How can I get my tabs and tab groups back? I had literally dozens of hours of work-related research saved in these tabs. I have so many visited sites in my history that there's no way I'd be able to recreate all of them.
    Please help--I'm desperate. I can't lose all of those tabs.

    Hello,
    '''Try Firefox Safe Mode''' to see if the problem goes away. [[Troubleshoot Firefox issues using Safe Mode|Firefox Safe Mode]] is a troubleshooting mode that turns off some settings, disables most add-ons (extensions and themes).
    If Firefox is open, you can restart in Firefox Safe Mode from the Help menu:
    *In Firefox 29.0 and above, click the menu button [[Image:New Fx Menu]], click Help [[Image:Help-29]] and select ''Restart with Add-ons Disabled''.
    *In previous Firefox versions, click on the Firefox button at the top left of the Firefox window and click on ''Help'' (or click on ''Help'' in the Menu bar, if you don't have a Firefox button) then click on ''Restart with Add-ons Disabled''.
    If Firefox is not running, you can start Firefox in Safe Mode as follows:
    * On Windows: Hold the '''Shift''' key when you open the Firefox desktop or Start menu shortcut.
    * On Mac: Hold the '''option''' key while starting Firefox.
    * On Linux: Quit Firefox, go to your Terminal and run ''firefox -safe-mode'' <br>(you may need to specify the Firefox installation path e.g. /usr/lib/firefox)
    When the Firefox Safe Mode window appears, select "Start in Safe Mode".<br>
    [[Image:Safe Mode Fx 15 - Win]]
    '''''If the issue is not present in Firefox Safe Mode''''', your problem is probably caused by an extension, and you need to figure out which one. Please follow the [[Troubleshoot extensions, themes and hardware acceleration issues to solve common Firefox problems]] article to find the cause.
    ''To exit Firefox Safe Mode, just close Firefox and wait a few seconds before opening Firefox for normal use again.''
    When you figure out what's causing your issues, please let us know. It might help others with the same problem.

  • I'm using FF 3.5.18 and I do not want newer versions because : using in the Open in New Tab page opens the near tab and not as a FF 3.5.18 or is it possible to do that open in new tabs would be the end. of the new FF version

    I'm using FF 3.5.18 and I do not want newer versions because : using in the Open in New Tab page opens the near tab and not as a FF 3.5.18 or is it possible to do that open in new tabs would be the end. of the new FF version

    You can change a preference to make tabs open
    # at the end of all open tabs
    # immediately after the current tab.
    See: http://kb.mozillazine.org/About:config
    *Type '''about:config''' in the URL bar and press the Enter key.
    *If you see the warning, accept it (promise to be careful).
    *Filter = browser.tabs.insertRelatedAfterCurrent
    *Look at the "Value" column ('''false'''=open at end, '''true'''=open after current tab); Value = true is the default.
    *Double-click that preference to toggle the value from true to false, or false to true
    *Restart Firefox (File > Restart Firefox)
    See: http://www.mydigitallife.info/2010/02/01/change-firefox-to-open-new-tab-at-far-right-end-of-tabbar-disable-insert-next-to-current-active-tab/

  • Tab and back-tab out of a JTable

    Hi There,
    I have been working for some time on improving the default behaviour of the tab key within editable JTables. It largely works as required now, but I'm stuck on getting back-tab to leave the table if on row 0, col 0. I register tab and back-tab action in the table's ActionMap that looks like this:     
         class TabAction extends AbstractAction {
              public void actionPerformed(ActionEvent e) {
                   if (getRowCount() > 0) {
                        int row = getSelectedRow();
                        int column = getSelectedColumn();
                        if (row < 0 || column < 0) {
                             row = 0;
                             column = 0;
                        do {
                             if (++column >= getColumnCount()) {
                                  row++;
                                  column = 0;
                        } while (row < getRowCount() && ! isCellTabbable(row, column));
                        if (row < getRowCount()) {
                             changeSelection(row, column, false, false);
                        } else {
                             clearSelection();
                             transferFocus();
                   } else {
                        transferFocus();
         class BackTabAction extends AbstractAction {
              public void actionPerformed(ActionEvent e) {
                   if (getRowCount() > 0) {
                        int row = getSelectedRow();
                        int column = getSelectedColumn();
                        if (row < 0 || column < 0) {
                             row = getRowCount() - 1;
                             column = getColumnCount() - 1;
                        do {
                             if (--column < 0) {
                                  row--;
                                  column = getColumnCount() - 1;
                        } while (row >= 0 && ! isCellTabbable(row, column));
                        if (row >= 0) {
                             changeSelection(row, column, false, false);
                        } else {
                             clearSelection();
                             transferFocusBackward();
                             KeyboardFocusManager fm = KeyboardFocusManager.getCurrentKeyboardFocusManager();
                                // fm.upFocusCycle(BTTTable_Editable.this);                         
                             // fm.focusPreviousComponent(BTTTable_Editable.this);
                   } else {     
                        // transferFocusBackward();
                        // KeyboardFocusManager fm = KeyboardFocusManager.getCurrentKeyboardFocusManager();
                           // fm.upFocusCycle(BTTTable_Editable.this);                         
                        // fm.focusPreviousComponent(BTTTable_Editable.this);
         }transferFocus() to go to the next screen component works fine - as long as I callsetFocusTraversalPolicyProvider(true); when I create the JTable.
    But the backward traversal just doesn't work - instead it does nothing the first time you press back-tab on row 0 col 0, then if you press it again, focus goes onto the last row/col of the table.
    As an alternative, I thought maybe I could call the Ctrl-back-tab action, but I can't find that registered in the action map - can anyone tell me how ctrl-back-tab is called and whether I can call that code directly?
    Any ideas?
    Thanks,
    Tim

    Where's the rest of your code? What good does posting
    the Actions do if we can't execute your code and see
    how you've installed the Actions on the table? Who
    knows where the mistake is. It may be in the posted
    code or it may be in some other code.Well I assume the Action is registered okay because back-tab within the table works fine, and in fact using a debugger I can see that the focus request code (transferFocusBackward) is being called at the right time. I followed it into that code and it appears that it is picking up the tableCellEditor as the "previous" component which is "why" it isn't working right - not that that helps me to fix it.
    Anyway, just to confirm, here is a complete standalone testcase:import java.awt.Dimension;
    import java.awt.GridBagConstraints;
    import java.awt.GridBagLayout;
    import java.awt.Insets;
    import java.awt.KeyboardFocusManager;
    import java.awt.event.ActionEvent;
    import java.awt.event.FocusEvent;
    import java.awt.event.FocusListener;
    import java.awt.event.InputEvent;
    import java.awt.event.KeyEvent;
    import javax.swing.AbstractAction;
    import javax.swing.ActionMap;
    import javax.swing.InputMap;
    import javax.swing.JComponent;
    import javax.swing.JFrame;
    import javax.swing.JPanel;
    import javax.swing.JScrollPane;
    import javax.swing.JTable;
    import javax.swing.JTextField;
    import javax.swing.KeyStroke;
    * <br>
    * <br>
    * Created on 14/11/2005 by Tim Ryan
    public class TabTable extends JTable implements FocusListener {
         protected KeyStroke TAB = KeyStroke.getKeyStroke(KeyEvent.VK_TAB, 0);
         protected KeyStroke BACK_TAB = KeyStroke.getKeyStroke(KeyEvent.VK_TAB,
                   InputEvent.SHIFT_DOWN_MASK);
         protected KeyStroke LEFT_ARROW = KeyStroke.getKeyStroke(KeyEvent.VK_LEFT, 0);
         protected KeyStroke RIGHT_ARROW = KeyStroke.getKeyStroke(KeyEvent.VK_RIGHT, 0);
         public TabTable(Object[][] rowData, Object[] columnNames) {
              super(rowData, columnNames);
              initialise();
         public TabTable() {
              super();
              initialise();
         private void initialise() {
              addFocusListener(this);
              InputMap inMap = getInputMap(JComponent.WHEN_ANCESTOR_OF_FOCUSED_COMPONENT);
              ActionMap actionMap = getActionMap();
              inMap.put(LEFT_ARROW, "None");
              inMap.put(RIGHT_ARROW, "None");
              actionMap.put(inMap.get(TAB), new TabAction());
              actionMap.put(inMap.get(BACK_TAB), new BackTabAction());
              setCellSelectionEnabled(true);
              putClientProperty("terminateEditOnFocusLost", Boolean.TRUE);
              setFocusTraversalPolicyProvider(true);
         public void focusGained(FocusEvent e) {
              if (getRowCount() > 0 && getSelectedRow() < 0) {
                   editCellAt(0, 0);
                   getEditorComponent().requestFocusInWindow();
         public void focusLost(FocusEvent e) {
         public void changeSelection(int row, int column, boolean toggle, boolean extend) {
              super.changeSelection(row, column, toggle, false);
              if (editCellAt(row, column)) {
                   getEditorComponent().requestFocusInWindow();
          * This class handles the back-tab operation on the table.
          * It repeatedly steps the selection backwards until the focus
          * ends up on a cell that is allowable (see <code>isCellTabbable()</code>).
          * If already at the end of the table then focus is transferred out
          * to the previous component on the screen.
         class BackTabAction extends AbstractAction {
              public void actionPerformed(ActionEvent e) {
                   if (getRowCount() > 0) {
                        int row = getSelectedRow();
                        int column = getSelectedColumn();
                        if (row < 0 || column < 0) {
                             row = getRowCount() - 1;
                             column = getColumnCount() - 1;
                        do {
                             if (--column < 0) {
                                  row--;
                                  column = getColumnCount() - 1;
                        } while (row >= 0 && ! isCellTabbable(row, column));
                        if (row >= 0) {
                             changeSelection(row, column, false, false);
                        } else {
                             clearSelection();
                             // transferFocusBackward();
                             KeyboardFocusManager.getCurrentKeyboardFocusManager().focusPreviousComponent();
                   } else {
                        // transferFocusBackward();
                        KeyboardFocusManager.getCurrentKeyboardFocusManager().focusPreviousComponent();
          * This class handles the tab operation on the table.
          * It repeatedly steps the selection forwards until the focus ends
          * up on a cell that is allowable (see <code>isCellTabbable()</code>).
          * If already at the end of the table then focus is transferred out
          * to the next component on the screen.
         class TabAction extends AbstractAction {
              public void actionPerformed(ActionEvent e) {
                   if (getRowCount() > 0) {
                        int row = getSelectedRow();
                        int column = getSelectedColumn();
                        if (row < 0 || column < 0) {
                             row = 0;
                             column = 0;
                        do {
                             if (++column >= getColumnCount()) {
                                  row++;
                                  column = 0;
                        } while (row < getRowCount() && ! isCellTabbable(row, column));
                        if (row < getRowCount()) {
                             changeSelection(row, column, false, false);
                        } else {
                             clearSelection();
                             transferFocus();
                   } else {
                        transferFocus();
          * Some cells can be tabbed to, but are not actually editable.
          * @param row
          * @param column
          * @return
         private boolean isCellTabbable(int row, int column) {
              return (column % 2 == 0);
         public boolean isCellEditable(int row, int column) {
              return (column == 1 || column == 3);
          * @param args
         public static void main(String[] args) {
              JFrame frame = new JFrame("Tables test");
              frame.setName("TablesTest");
              frame.setSize(600, 400);
              frame.setDefaultCloseOperation(JFrame.EXIT_ON_CLOSE);
              JPanel panelMain = new JPanel(new GridBagLayout());
              frame.add(panelMain);
              Object[][] tableData = new Object[2][6];
              Object[] columnHeadings = new Object[] {"H0", "H1", "H2", "H3", "H4", "H5"};
              GridBagConstraints gbc = new GridBagConstraints();
              gbc.anchor = GridBagConstraints.NORTH;
              gbc.insets = new Insets(10, 10, 10, 10);
              JTextField field1 = new JTextField("left", 8);
              field1.setName("left");
              panelMain.add(field1, gbc);
              Dimension tableSize = new Dimension(300, 300);
              BTTTable table3 = new BTTTable_Editable(tableData, columnHeadings);
              table3.setName("Editable");
              JScrollPane scroll3 = new JScrollPane(table3);
              scroll3.setPreferredSize(tableSize);
              panelMain.add(scroll3, gbc);
              JTextField field2 = new JTextField("right", 8);
              field2.setName("right");
              gbc.gridwidth = GridBagConstraints.REMAINDER;
              panelMain.add(field2, gbc);
              frame.setVisible(true);
    }I thought it might be the focusGained() code, but commenting that out makes no difference.
    And here is the code I would use to go to the
    previous component:
    KeyboardFocusManager.getCurrentKeyboardFocusManager().
    focusPreviousComponent();I tried that too, as you can see from my original post. It gives the same answer.
    So the big question is why does the FocusManager think that the "previous" field to the table is an editor component within the table?
    Regards,
    Tim

  • With multiple tabs open, crashing with no warning to close tabs and no crash report. Just bye-bye.

    I have the option to warn me before closing multiple tabs selected. I left my desk for an hour with multiple windows open. When I returned, all but 1 window disappeared. I was typing on Facebook with multiple tabs open and instantly all tabs and windows disappeared without warning. No crash report either. I search for the keyboard shortcut to close a window (Alt+Spacebar+C). I tested with multiple tabs open, no warning - just instantly closed. I do not think I hit these keys by accident and I would like an option for a warning with one tab open or multiple tabs.

    Ok I solved the problem if anyone is looking at this.
    Add on "Hide Caption Title bar Plus" was the offender
    Option - define option for close button. Was on recommended not default.
    Choose default, problem eliminated!
    Andy

  • I had on my desk top pc (a vista os) a version of FireFox that the book marks where listed in the book tool bar tab and the "book tool" was able to show all my favs and there was a scrol bar on the right side of the top right side. I would like very much

    I had on my desk top PC (a vista OS) a version of FireFox that the book marks where listed in the book tool bar tab and the "book tool" was able to show all my favs and there was a scroll bar on the right side of the top right side. I would like very much to turn it on in the Laptop I just bought and am having a fit trying to figure out all the differences,.I very much like this function; however, I am now using win 7 which in and of itself is difficult to figure out troubles when they occur such as if the MSN Bing program opens a video window while I am playing, the media center will lock up, or if I am listening to BBradio.org and click on lestening to one of the pastors the laptop will show static on the screen and all you hear is static like you just went to the twilight zone.
    == This happened ==
    Not sure how often
    == unpredictable

    To attempt a new chat session...
    For the link below click the Still Need Help? option in the blue area at the bottom and choose the chat option...
    http://helpx.adobe.com/x-productkb/global/service1.html

  • Open in an new tab and open in a new window - both dissapeard

    open in an new tab and open in a new window - both dissapeard
    where have they dissapeard to?
    how can i bring them back?
    thanks !!!!!!!!!

    Please press alt and tab and using tab to scroll through windows and see if the window you opened exist. If this happens every time you open a new window you may want to try safe mode:
    Hello,
    '''Try Firefox Safe Mode''' to see if the problem goes away. Safe Mode is a troubleshooting mode, which disables most add-ons.
    ''(If you're not using it, switch to the Default theme.)''
    * You can open Firefox 4.0+ in Safe Mode by holding the '''Shift''' key when you open the Firefox desktop or Start menu shortcut.
    * Or open the Help menu and click on the '''Restart with Add-ons Disabled...''' menu item while Firefox is running.
    ''Once you get the pop-up, just select "'Start in Safe Mode"''
    '''''If the issue is not present in Firefox Safe Mode''''', your problem is probably caused by an extension, and you need to figure out which one. Please follow the [[Troubleshooting extensions and themes]] article for that.
    ''To exit the Firefox Safe Mode, just close Firefox and wait a few seconds before opening Firefox for normal use again.''
    ''When you figure out what's causing your issues, please let us know. It might help other users who have the same problem.''
    Thank you.

Maybe you are looking for

  • How do i remove old iphone backups on my itunes to free up disk space on my hard drive?

    im running low on diskspace and dont have much on my pc other than my itunes. i think the problem is all the iphone backups i have.. i have more than one iphone and have had all the generations. so i think tat my backups are using a lot of diskspace

  • IDVD annoyance!!!

    Okay, so I'm burning a quicktime file onto a DVD through iDVD. The entire file is actually around 12.6 GB, so I had to buy a DVD with Dual Layer so that it could actually fit. When exporting this quicktime file out of Final Cut Pro, I used the best q

  • Hot Spot question...

    Hello All, I'm creating a SCORM quiz to put into our LMS. I am using a Hot Spot question slide and I'm not happy with how is works and would like to change it slightly. I have inserted an image to the slide and setup my hot spot area but I don't like

  • Removing child via hitTestObject

    Before i ask what im sure will be a very silly question, let me say that i am a total beginner at Action Script. I am trying my best to make a simple game for University, and i have tried, but cant figure it out. Anyway, the game is basically Breakou

  • Extra Display with ARD

    When I login to one of my clients (Powerbook G4) via ARD, it has two displays which show in ARD. They are not evident when the machine is being used as a standalone. This has the effect of hiding windows etc. I have partly solved it from a user persp