Strange UCSM GUI Java again?

Hello

Since a few days, I've had UCSM Gui appears in this way:

as you can see, no image of the chassi ucs do appear.

I used to see from time to time buy now its seem permanent. (usually reload to get rid of this problem)

I tried to reinstall Java version 7.25 nothing helps.

Clear the java cache, use direct connect.  No change.

the ides are welcome.

Stéphane Beausoleil

Senior SysAdmin / virtualization team

CGI

Stephane,

Thanks for posting comments. If possible, mark your message as "answered" if other users can see you found the reason for the failure.

-Kenny

Tags: Cisco DataCenter

Similar Questions

  • 2.0(1t) UCSM dislikes Java 1.7

    Guys,

    I have no chance whatsoever with UCSM 2.0(1t) departure on a Windows 2003 R2 (32-bit) machine: it says "Java detected 1.7, Java 1.6 (or MORE) required.

    The notes say: "the Cisco UCS Manager GUI is a Java application that requires Sun JRE 1.6 or higher.

    So what's the bottom line - will I expect UCSM 2.0 to work with Java 1.7, or not?

    Kind regards

    Radek

    Javea 1.7 is supported on version 2.0 (3) and newer.  2.0 (3) is currently available for download from EAC.

    Kind regards

    Robert

  • GUI shows again the old size after expansion VMDK

    I extended VMDK using vmkfstools, extended successfully got drive and my windows VM has detected the drive extended and used diskpart to extend the volume.

    Now when I see the size of the disk hard in VC it still shows the old value of disc size. Even my free size of the data store has not been reduced. I did a rescan and got reduced the size of my data store. But the VM disk size still old.

    We use esx 3.0

    Please help on this...

    Restart the services mgmt and vpxa.

    Or remove the virtual machine from the inventory and add it back again.

    André

  • Strange error in java. What it means?

    "An error occurred to perform the requested operation."
    No odjdbc11 in the java.library path
    code provider 0 "

    Using the most recent version of sustainable development, which works on some PCs but not on others. It does not matter which version of JRE is installed on the machines involved.

    AFAIK SQLDeveloper requires a specific version of the local client oracle (or instant client) must be installed to use connections of the OIC, in which case the client version installed does not match, you may encounter an error similar to the one displayed.

    To check this, you should go to

    Tools-> preferences-> database-> advanced

    and make sure that the indicator, use the driver OIC/thickness is not checked, with this indicator supported off the missing library should no longer be necessary.

    Of course if you need to use the driver of the OIC for a reason, you then need to install a different version of the Oracle Client on the affected PC (11g or later should be enough).

  • Strange behavior of Java NIO

    Hello

    my server code follows the well known model as follows;
    while (enabled) 
        try {
            int count = selector.select();
    
            Iterator<SelectionKey> it = selector.selectedKeys().iterator();
            while (it.hasNext())
            {
                SelectionKey key = (SelectionKey) it.next();                        
    
                it.remove();
                            
                if (key.isAcceptable())
                {
                    ...                            
                    final SelectionKey newKey = channel.register(
                                 selector, SelectionKey.OP_READ, cd);
                    ...
                    continue;
                }
    
                if (key.isReadable()) {
                          
                    key.interestOps(key.interestOps() & (~SelectionKey.OP_READ));
                                
                    threadPool.execute((Runnable) key.attachment());
                }
    
                if (key.isWritable()) {                   
                    ...
                }
            }                    
        }
    
    } catch (Exception ex) {
        logger.error(ex, ex);
    }
    The reading of the channel is delegated to a worker threads provided by the thread pool.
    It runs the code of a State attached to the key object. At the end of the reading process, I place the interest of the READING to true:
    ...
    key.interestOps(key.interestOps() | SelectionKey.OP_READ);        
    
    key.selector().wakeup();
    ...
    The problem is, once I have an essential interest of the selector READ off and on, then touch get more never selected for preparation even it has data queued on the socket.

    I checked with tcpdump and I can confirm that the data arrived, but the channel never get back selected by the selector.

    Any ideas what could cause this behavior?

    my server code follows the well known model as follows;

    There are aspects which are not "well known" for me.

    threadPool.execute((Runnable) key.attachment());
    

    Why? You already know there is data, you can read it without blocking: why start another thread to do what you can do perfectly well here?

    The reading of the channel is delegated to a worker threads provided by the thread pool.

    Why?

    It runs the code of a State attached to the key object. At the end of the reading process, I place the interest of the READING to true:

    Crashes because of the timing specified in the Javadoc for interestOps() and select(). This is why you don't want to do this in a separate thread. NIO is all on a single thread. Do it this way. If you have zilliions connections, or of the tens of CPUs, running multiple threads of selector and have all manage their own connections. Don't even think on the I/O delegation to other threads as well, it is infinitely more trouble that it's worth.

  • List UCSM offshore all Webinterface .jar files / McAfee blocked ccore.jar

    Hi guys,.

    I'm looking for a list of all the .jar files UCSM loads at startup, basically the folder/ucsm/unpacked.

    We are using MCafee Enterprise 8.8 AV and it seems to block access to the ccore.jar file.

    I'm trying to get a rule file for exclusion from our IT for management servers, and I was wondering if someone could give me a list of these files.

    If you know of a fix for the issue that has no exception rules you are welcome to help me

    Kind regards

    Constantin

    If you open the file ucsm.jnlp (the file that will be downloaded on your machine when you try to launch UCSM GUI) in a text editor, then you will see entries like:

    and this will give you the complete list of jar files downloaded from the switch on your machine for the launch of GUI de UCSM.

    for example

    http://java.sun.com/products/autodl/j2se' java-vm-args = "" - Dsun.java2d.d3d = false - XX: + HeapDumpOnOutOfMemoryError - XX: MaxPermSize = 256 m "initial heap size ="128 M"max-heap-size ="768 M"/ >"

    Thank you
    Varun

  • After the "new version" download Java 6 times, my plugin check page indicates that he has disabled my 'version outdated' and asks me to upgrade. What do I do?

    Background:
    I had this problem for several months now. This problem started when an update came to Java on the Firefox Plugin check. Quickly, I installed the new update of Java. But the Firefox update register that I downloaded, even though I refreshed the page. So, I got rid of the old Java and downloaded again the new Java. When the page has continued to post the same message he had before, I downloaded a few times more. Finally, Firefox stopped to say that I was at day. Then a few weeks later perhaps I check Firefox Plugin, and on the page it says that I'm overwhelmed in Java. So I downloaded Java again. But Java was still in the list, with the red and said that he had to be updated. I restarted the computer. Then I restarted Firefox Mozilla with no Add-ons. When Java appeared still to be updated, I gave up and did not something more on this topic.
    Problem:
    Today, I decided to check my plugins. Java was not updating the list, and at the top a banner said, "Missing JAVA? For your security, Firefox has disabled your outdated version of Java. Please install the latest version. "I clicked on"upgrade to the latest version"and was brought to the Java page. I clicked on the download button. My cache indicates that it was this same Java plug-in (see background) download (6). I chose the re - download anyway. But Firefox always insists on the fact that I him have not downloaded.
    Question:
    Should I go to the control panel of Java and change something? I have to fix a few settings on Firefox? Should I disable Java entirely, delete all the files related to Java on my computer and start over with Java? What should I do?

    Try to use http://ninite.com/java/ninite.exe to install Java. Please note that even if download you it you have to double click it to run and install.

  • Java JRE does not not on Satellite Z830-10U

    I had my Z830-10U yesterday and started setting up. When I tried to load a few things that require Java Run Time, they all failed. I went to the site of Java and ran his detector who told me that the plugin was not installed. Then I went and checked and in my list of installed programs is Java Run Time.

    Thus, assuming that the installation of the factory was not right, that I downloaded the latest version of the drivers from the website of Java, uninstalled Java, restarted and installed Java again. No joy. Yet once again, I rebooted and tried to reinstall once again no luck at all (in fact I tried several times)

    Does anyone have any suggestions?

    I would also like to point out that I made sure that the previous version had been uninstalled before attempting to add the new version

  • Difficulty of java that keeps repeatedly stop working...

    Java has stopped working properly. To resolve this issue, follow these steps:

    I uninstalled and reinstalled java again and again... Unable to display some of them to the bottom of the computer hangs using loads

    Thank you

    You might get answers to Support Java:

    This is one of the links:
    http://Java.com/en/download/help/index_using.XML?user_os=Vista For the benefits of others looking for answers, please mark as answer suggestion if it solves your problem.

  • Entries strange/unknown/not identified/ruleless VISTA will

    Hello world!
    My machine with vista business sp1, creates strange/unknown/no entries identified in services.msc since I bought it.
    There are some following examples listed.
    20/5/2009, created Hdaoteaue.
    2009/5/5, Sym_996 created.
    2009/4/8, created Exfatrsnt.
    31/3/2009, created Viarvmtsmtl.
    30/3/2009, created Gys55clpp.
    19/3/2009, created Hdaknempfrn.
    2009/3/6, created .netvewi. ...
    All strange services are not ENABLED by default.
    All drivers and windows updates are up to date.
    NO spyware, virus or Trojan are beeing found.
    My software has been sofz normally installed, SO illegal.
    I remove entries from regeit, located HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Services\, but about two weeks later, then, the STRANGE service will create again.
    What's wrong? I have no idea.

    http://social.answers.Microsoft.com/forums/en-us/vistaprograms/thread/8727904f-87c8-4667-8bf4-dad33399690e

    Hello MG-42,

    Thank you for visiting the website of Microsoft Windows Vista Community.

    I suggest that you try to start your computer by using a minimal set of drivers and startup programs so that you can determine if a background program is interfering with your computer.

    Try to perform a clean boot on a computer that is running Windows Vista, follow these steps.

    1. click on start toreduce this includes this image, type msconfig in the Search box and press ENTER. Collapse this includes this image

    If you are prompted for an administrator password or a confirmation, type the password, or click continue.

    2. in the general tab, click Selective startup.

    3. under Selective startup, clear the Load Startup items check box.

    4. click on the Services tab, select the hide all Microsoft Services check box, and then click disable all.

    5. click on OK.

    6. When you are prompted, click restart.

    7. after the computer starts, start the program or game and see if the problem is resolved.

    Another option to resolve this problem, use the tool (SFC.exe) System File Checker to determine which file is causing the problem and then replace the file. To do this, follow these steps:

    1. open an elevated command prompt. To do this, click Start, click principally made programs, Accessories, right-click guest, and then click run as administrator. If you are prompted for an administrator password or a confirmation, type the password, or click allow.

    2. type the following command and press ENTER:

    sfc/scannow

    The sfc/scannow command analyzes all protected system files and replaces incorrect versions with appropriate Microsoft versions.

    Let us know if these steps solve your problem.  I hope the information is useful.

    Kind regards

    Anthony
    Microsoft Answers Support Engineer
    Visit our Microsoft answers feedback Forum and let us know what you think.

  • Only access via UCSM KVM

    I am able to restrict users to the KVM console only in UCSM?

    What are the roles I have to assign to the user to ensure that all they can do is access the KVM Console?

    It is not a huge problem if they get the UCSM itself read-only rights.

    Create a role called "KVM-Only" or similar and affect only the privilege of "service-profile-server-oper.  Then, create a user as "KVM User" and him given that the role of KVM only.  They will be able to launch the full UCSM or KVM Launcher, but only have privileges access KVM.

    Alternative if you want to only grant access KVM while preventing access by connection/UCSM.     Configure an IPMI profile with ipmi-user named something like 'helpdesk' for example. Creating 'helpdesk' offer the privilege of ipmi admin. assign this IPMI-profile to the profile of your server service.      Then use the following link on your browser

    http:///ucsm/kvm.jnlp

    or

    http:///ucsm/kvm.jnlp?kvmIpAddr=w.x.y.z (where w.x.y.z is the Management IP
    of the blade or Service profile you wish to provide access to)

    It will open a KVM connection screen. Enter the username 'helpdesk' and assigned password and the MMIC-server you have configured IP address.  Address IP of MMIC lie on the Hardware tab, by selecting the blade, then the right selection inventory - MMIC.  The MMIC IP is listed under the section "Management Interface."             This will open the KVM from that server. Also, the ipmi vinay-kvm user only WILL NOT be able to connect to regular UCSM GUI Note that in version 1.3 - MMIC IP is static and will remain with the hardware of server/slot.  In the latest version 1.4, you can join the IP of CIMC/IPMI address your service profile so that it will follow him around everywhere where the profile is associated with.

    Kind regards

    Robert

  • Why as I get Install Java games pogo - this happened today and if I reinstall still the same

    Today, when I went on Pogo to play games I've had that need to install Java.  So I reinstalled and still can not play in Pogo.  Just a window to install Java again and again. I am very disappointed by Windows 7 Home Premium.

    Hi l. a. Crooks,.

    ·         What happens when you try to play Pogo games, you receive no error message?

    ·         What version of IE are you using?

    I suggest you try the steps below and check if it helps

    Method 1: Try to download Microsoft Silver light of the link below

    http://www.Silverlight.NET/

    Silver light is a free plug-in software, powered by the .NET framework and compatible with multiple browsers, devices and operating systems, bringing a new level of interactivity, everywhere where the Web works.

    Method 2: In addition, I suggest you to uninstall Java completely from programs and features, and then reinstall the latest version of Java from this link.

    http://www.Java.com/en/

    Then check if you are able to play the games in Internet Explorer.

    Reference:

    Uninstall or change a program

    http://Windows.Microsoft.com/en-us/Windows7/uninstall-or-change-a-program

    More information: Try working through the steps provided here to resolve the error you receive everything by trying to play Pogo games:

    Java - how to solve some problems running Pogo games?

    http://www.Java.com/en/download/help/Pogo.XML

    Hope this information helps.

  • Java problem with guest 10.7 Lion (64-bit)

    VmWare: 4.1.1 (536016)

    OS: Mac OS X Lion 10.7.3 (64-bit)

    Guest OS: Mac OS X Lion 10.7.3 (64-bit)

    Java comments: 1.6.0_29

    Hello

    I am facing a strange behavior with java applications in my guest operating system.

    in most java applications I am running (intellij idea, jmeter) I can't use the functionaltiy filebrowse

    to open the files. I see all of the available records, but I'm not able to open them.

    in other java applications, nothing happens when I click on the UI elements.

    to me, it seems that something with java awt/swt does not work correctly.

    as my host OS is identical to the guest, I tested everything what it and it worked fine.

    someone has any idea how to solve this problem?

    thx for you're help!

    Hi mariusband welcome to the VMware communities!

    I think that the strange behavior that you see is the result of a workaround that we added to a problem of pointer movement mouse villain which exists in Mac OS 10.7.2 clients.  If you're on 10.7.3 and don't plan to go back to 10.7.2, you can disable workaround (and hopefully restore the correct behavior of your Java applications) by judgment of the virtual machine and change the configuration of the virtual machine file to add:

    mouse.vusb.absVibration = "FALSE".

    Please let us know if that solves your problem!

    See you soon,.

    --

    Darius

  • Java Swing-how do I get the value of a JTable to display dynamically in a JPanel

    I need the sum of the values from the values entered in the JTable to be included in the text of the partition field in the adjoining JPanel.
    Also posted here - http://www.coderanch.com/t/512189/GUI/java/value-JTable-show-up-dynamically.
    import javax.swing.*;
    import javax.swing.table.*;
    import javax.swing.event.*;
    import javax.swing.table.DefaultTableCellRenderer;
    
    import java.awt.*;
    import java.util.*;
    import java.awt.color.*;
    import java.awt.event.*;
    
    public class TableandPanel extends JFrame
    {
         public static void main(String[] args)
         {
              JFrame frame = new JFrame("Table and Panel");
                                           frame.setDefaultCloseOperation(JFrame.EXIT_ON_CLOSE);
                                           frame.setSize(100, 300);
            
                                            frame.setVisible(true);
                  String colHdrA = "Some Values";                    
                  TableofSums tableofSums = new TableofSums(10, colHdrA);
                  int sumValue = tableofSums.getSumValues();
                  String sumValueS = String.valueOf(sumValue);
                  SumValuesPanel newPanel = new SumValuesPanel( "Score", sumValueS, "Rank");
                  JPanel thePanel = new JPanel();
                  thePanel.add(new JScrollPane(tableofSums));
                  thePanel.add(newPanel);
                  frame.add(thePanel);
                  frame.pack();
              frame.setVisible(true);
         }
    }
    
    //---------table class starts here---------------------------
    
    public class TableofSums extends JPanel implements TableModelListener
    {
        public static void main(String[] args)
         {          
             SwingUtilities.invokeLater(new Runnable() 
                {
                    public void run() 
                      {               
             JFrame frame = new JFrame("Table");
             frame.setDefaultCloseOperation(JFrame.EXIT_ON_CLOSE);
             frame.setSize(208, 230);
             //frame.add(new JScrollPane(table));
                frame.setVisible(true);
                String colHdrA = "Some Values";                    
                TableofSums tableofSums = new TableofSums(10, colHdrA);
                 frame.setContentPane(tableofSums);
                  //frame.add(new JScrollPane(timerepTable));
               frame.pack();
               frame.setVisible(true);
                       
                   }
                });
         }
         
         private int noOfRows = 0;
         private JTable table;
         private String colName = null;
         private int sumValues = 0;
         
         public TableofSums(int noOfRows, String colName)
         {
              this.noOfRows = noOfRows;
              this.colName = colName;
              makeTable();          
         }
         
         private void makeTable()
         {
              Object columns[] = new Object[] {"<html><center>" + this.colName + "</center></html>"};
              
             Object[][] data = new Object[noOfRows][1];
             
             for (int i = 0; i<noOfRows; i++)
                {                
                    data[0] = new Integer(0);          
         }
         DefaultTableModel model = new DefaultTableModel(data, columns);
         model.addTableModelListener(this);
         table = new JTable(model)
         {
         @Override
         public boolean isCellEditable(int row, int column)
         {
         switch (column)
         {
              case 0: return true;
         }
         return false;
         }
         
         @Override
         public Class<?> getColumnClass(int columnIndex)
         {
         switch (columnIndex)
         {
         case 0: return Integer.class;
         }
         return null;
         }
         };
         table.setRowHeight(25);
         table.setDefaultRenderer(Integer.class, new SomeCellRenderer());
         this.add(new JScrollPane(table));
         }

    ///--------------------------------tablemodellistener---------------------------------
    //gets the values entered in the table and calculates the sum
    //-------------------------------------------------------------------------------------------
         public void tableChanged(TableModelEvent e)
    {
         System.out.println(e.getSource());
         if(e.getType() == TableModelEvent.UPDATE)
         {
              int row = e.getFirstRow();
              int column = e.getColumn();
              TableModel model = table.getModel();
              sumValues = 0;
              for (int i=0; i<noOfRows; i++)
              {
                   int intValue = (Integer)model.getValueAt(i, column);
                   sumValues += intValue;
              }
              System.out.println ("row modified: " + row + " sumValues: " + sumValues);
         }
         
    }
    //--------------------------------------cell renderer------------------------------------------------------
         
         public class SomeCellRenderer extends JLabel implements TableCellRenderer
         {
              
         public SomeCellRenderer()
         {
              setOpaque(true);      
         }

         public Component getTableCellRendererComponent(JTable table, Object
                   value, boolean isSelected, boolean hasFocus, int row, int column)
              {
              String cellValue = String.valueOf(value);
              this.setText(cellValue);
              this.setBackground(Color.LIGHT_GRAY);
              this.setHorizontalAlignment(SwingConstants.CENTER);
         return this;
              }
         }
         public int getSumValues()
         {
              return sumValues;
         }
    }


    //-------------------------Panel Class Starts here-------------------------------------

    public class SumValuesPanel extends JPanel
    {
         /**
         * @param args
         */
         public static void main(String[] args)
         {
              JFrame.setDefaultLookAndFeelDecorated(true);
              JFrame frame = new JFrame("SumValuesPanel");
              frame.setDefaultCloseOperation(JFrame.EXIT_ON_CLOSE);
              SumValuesPanel newContentPane = new SumValuesPanel( "Score", "XX.XX", "Rank");
              
              frame.setContentPane(newContentPane);
              frame.pack();
              frame.setVisible(true);
         }
         
    //------Variables declaration
    private JPanel thePanel;
    private JLabel scorejLabel;
    private JTextField ScorejTextField;
    private String scoreLabel;
    private String scoreValue;
    private JLabel rankLabel;
    private String rankLabelTxt;
    private JTextField rankTextField;
    private String rankText;
    //-------End of variables declaration

    public SumValuesPanel (String setScoreLabel,String setScoreVal, String rankLabel)
    {
         scoreLabel = setScoreLabel;
         scoreValue = setScoreVal;
         this.rankLabelTxt = rankLabel;
              
         createSumValuesPanel();
    }

    private void createSumValuesPanel()
    {         
    thePanel = new JPanel();

    rankLabel = new JLabel();
    rankTextField = new JTextField();
         scorejLabel = new JLabel();
    ScorejTextField = new JTextField();

    thePanel.setBackground(new Color(235, 233, 230));
    thePanel.setBorder(BorderFactory.createLineBorder(new Color(0, 0, 0)));
    thePanel.setPreferredSize(new Dimension(200, 180));

    scorejLabel.setHorizontalAlignment(SwingConstants.CENTER);
    scorejLabel.setText(scoreLabel);
    scorejLabel.setBorder(BorderFactory.createLineBorder(new Color(0, 0, 0)));
    scorejLabel.setPreferredSize(new Dimension(40, 20));

    ScorejTextField.setEditable(false);
    ScorejTextField.setHorizontalAlignment(JTextField.CENTER);
    ScorejTextField.setText(scoreValue);
    ScorejTextField.setBorder(BorderFactory.createLineBorder(new Color(0, 0, 0)));
    ScorejTextField.setMaximumSize(new Dimension(60, 25));
    ScorejTextField.setMinimumSize(new Dimension(35, 15));
    ScorejTextField.setPreferredSize(new Dimension(55, 20));

    rankLabel.setHorizontalAlignment(SwingConstants.CENTER);
    rankLabel.setText(rankLabelTxt);
    rankLabel.setBorder(BorderFactory.createLineBorder(new Color(0, 0, 0)));
    rankLabel.setPreferredSize(new Dimension(90, 20));

    rankTextField.setEditable(false);
    rankTextField.setBackground(new Color(255,255,0));
    rankTextField.setHorizontalAlignment(JTextField.CENTER);
    rankTextField.setText(rankText);
    rankTextField.setBorder(BorderFactory.createLineBorder(new Color(0, 0, 0)));
    rankTextField.setPreferredSize(new Dimension(55, 20));

    thePanel.add(scorejLabel);
    thePanel.add(ScorejTextField);
    thePanel.add(rankLabel);
    thePanel.add(rankTextField);

    this.add(thePanel);
    }

    }
    Edited by: 799076 on Oct 1, 2010 8:50 AM
    
    Edited by: 799076 on Oct 2, 2010 3:59 AM - added the code tags.
    
    Edited by: 799076 on Oct 2, 2010 4:01 AM                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            

    OK, here's my "simple" example Say you have a class, TablePanel, that extends from JPanel that holds a JTable and this table contains two columns of integers in a DefaultTableModel and you want to get and display the sum of the columns of numbers whenever they are changed:

    class TablePanel extends JPanel {
       public static final String[] COL_HEADERS = {"A", "B"};
       private static final Integer[][] DATA = {{1, 2}, {3, 4}, {5, 6}};
       private DefaultTableModel model = new DefaultTableModel(DATA, COL_HEADERS) {
          @Override
          public Class getColumnClass(int columnIndex) {
             return Integer.class;
          }
       };
    
       public TablePanel() {
          JTable table = new JTable(model);
          setLayout(new BorderLayout());
          add(new JScrollPane(table));
       }
    //....
    

    A way to listen for changes to the table is to provide a method that allows outside classes to add a TableModelListener your JTable model:

       public void addTableModelListener(TableModelListener listener) {
          model.addTableModelListener(listener);
       }
    

    You could also give him public methods to enable this class get the money and return:

       public int getSumA() {
          int sum = 0;
          for (int i = 0; i < model.getRowCount(); i++) {
             sum += (Integer) model.getValueAt(i, 0);
          }
          return sum;
       }
    
       public int getSumB() {
          int sum = 0;
          for (int i = 0; i < model.getRowCount(); i++) {
             sum += (Integer) model.getValueAt(i, 1);
          }
          return sum;
       }
    }
    

    While you have another class, SumPanel, that displays two JLabels, one to hold the sum of column A and one for the sum of column B:

    class SumPanel extends JPanel {
       private JLabel sumA = new JLabel(" ", SwingConstants.RIGHT);
       private JLabel sumB = new JLabel(" ", SwingConstants.RIGHT);
    
       public SumPanel() {
          setLayout(new GridLayout(1, 0));
          add(sumA);
          add(sumB);
    
          //....
       }
       //.....
    

    You'd give public methods to allow outside classes to set the text for the JLabels that class:

       public void setTextSumA(String text) {
          sumA.setText(text);
       }
    
       public void setTextSumB(String text) {
          sumB.setText(text);
       }
    

    Then, you might have your own class TableModelListener, ModelListener, which has references to both of the above classes:

    class ModelListener implements TableModelListener {
       private TablePanel tablePanel;
       private SumPanel sumPanel;
    
       public ModelListener(TablePanel tablePanel, SumPanel sumPanel) {
          this.tablePanel = tablePanel;
          this.sumPanel = sumPanel;
    
          //...
       }
    //....
    

    who will set the SumPanel labels whenever its tableChanged method is called by the model:

       @Override
       public void tableChanged(TableModelEvent e) {
          int sumA = tablePanel.getSumA();
          int sumB = tablePanel.getSumB();
    
          sumPanel.setTextSumA(String.valueOf(sumA));
          sumPanel.setTextSumB(String.valueOf(sumB));
       }
    
    }
    

    Then you can link everything together in your main graphical interface as follows:

          TablePanel tablePanel = new TablePanel();
          SumPanel sumPanel = new SumPanel();
          ModelListener myModelListener = new ModelListener(tablePanel, sumPanel);
          tablePanel.addTableModelListener(myModelListener);
    

    All assembled, it could look as follows:

    import java.awt.*;
    import javax.swing.*;
    import javax.swing.event.*;
    import javax.swing.table.DefaultTableModel;
    
    public class TableAndPanel2 {
    
       private static void createAndShowUI() {
          TablePanel tablePanel = new TablePanel();
          SumPanel sumPanel = new SumPanel();
          ModelListener myModelListener = new ModelListener(tablePanel, sumPanel);
          tablePanel.addTableModelListener(myModelListener);
    
          JFrame frame = new JFrame("Table And Panel 2");
          frame.getContentPane().add(tablePanel, BorderLayout.CENTER);
          frame.getContentPane().add(sumPanel, BorderLayout.PAGE_END);
          frame.setDefaultCloseOperation(JFrame.EXIT_ON_CLOSE);
          frame.pack();
          frame.setLocationRelativeTo(null);
          frame.setVisible(true);
       }
    
       public static void main(String[] args) {
          java.awt.EventQueue.invokeLater(new Runnable() {
             public void run() {
                createAndShowUI();
             }
          });
       }
    }
    
    class TablePanel extends JPanel {
       public static final String[] COL_HEADERS = {"A", "B"};
       private static final Integer[][] DATA = {{1, 2}, {3, 4}, {5, 6}};
       private DefaultTableModel model = new DefaultTableModel(DATA, COL_HEADERS) {
          @Override
          public Class getColumnClass(int columnIndex) {
             return Integer.class;
          }
       };
    
       public TablePanel() {
          JTable table = new JTable(model);
          setLayout(new BorderLayout());
          add(new JScrollPane(table));
       }
    
       public void addTableModelListener(TableModelListener listener) {
          model.addTableModelListener(listener);
       }
    
       public int getSumA() {
          int sum = 0;
          for (int i = 0; i < model.getRowCount(); i++) {
             sum += (Integer) model.getValueAt(i, 0);
          }
    
          return sum;
       }
    
       public int getSumB() {
          int sum = 0;
          for (int i = 0; i < model.getRowCount(); i++) {
             sum += (Integer) model.getValueAt(i, 1);
          }
    
          return sum;
       }
    
    }
    
    class SumPanel extends JPanel {
       private JLabel sumA = new JLabel(" ", SwingConstants.RIGHT);
       private JLabel sumB = new JLabel(" ", SwingConstants.RIGHT);
    
       public SumPanel() {
          setLayout(new GridLayout(1, 0));
          add(sumA);
          add(sumB);
    
          sumA.setBorder(BorderFactory.createLineBorder(Color.black));
          sumB.setBorder(BorderFactory.createLineBorder(Color.black));
       }
    
       public void setTextSumA(String text) {
          sumA.setText(text);
       }
    
       public void setTextSumB(String text) {
          sumB.setText(text);
       }
    }
    
    class ModelListener implements TableModelListener {
       private TablePanel tablePanel;
       private SumPanel sumPanel;
    
       public ModelListener(TablePanel tablePanel, SumPanel sumPanel) {
          this.tablePanel = tablePanel;
          this.sumPanel = sumPanel;
    
          tableChanged(null);
       }
    
       @Override
       public void tableChanged(TableModelEvent e) {
          int sumA = tablePanel.getSumA();
          int sumB = tablePanel.getSumB();
    
          sumPanel.setTextSumA(String.valueOf(sumA));
          sumPanel.setTextSumB(String.valueOf(sumB));
       }
    
    }
    
  • 9.0.4 to 10.1.2 upgrade error ora-00600

    We are modernizing our 9.0.4 to 10.1.2 forms... We have a few problems of conversion of a couple of forms. Most of the forms convert a major just fine and working. One of the forms has this error in a when button pressed trigger...
    ora-00600: internal error code, arguments: [KGHALO2], [0x0], [], [], [], [], [], []
    I commented some code of the trigger until the error has disappeared. Form builder is having a problem with a call of plsql database package.procedure which is actually a wrapper of a java class stored in the database. The code in this 10.1.2 form is identical to the code in the 9.0.4 form. The 9.0.4 form works very well and calls this wrapper a - OK. The 10.1.2 form get the above error. This error occurs when compiling the code when the button is pressed in the form on my local pc Builder and trying to compile the form on the application server. Am I missing a java parameter somewhere in both places?

    create or replace
    PACKAGE        sims_marrs_report IS
    
      PROCEDURE insert_clob_data(dot_case_num    in  varchar2,
                                 docxml_id       in  number,
                                 temp_report_pk  in  number,
                                 marrs_report_pk in  number,
                                 out_error       out varchar2)
      as language java name
         'AccidentReport.create(java.lang.String,
                                oracle.sql.NUMBER,
                                oracle.sql.NUMBER,
                                oracle.sql.NUMBER,
                                java.lang.String[])';
    
    .....
    
    end;
    Published by: Mark Reichman on October 16, 2008 14:46

    ORA-00600 should generally be registered to oracle support.

    BTW... what version of the database you use?

    Perhaps a work around:

    wrap your wrapper java again in a pure pl/sql-procedure that then calls the java wrapper.

    Sounds strange, but can work.

Maybe you are looking for