This site requires JavaScript, please enable it in your browser!
Greenfoot back
Nonob
Nonob wrote ...

2013/9/30

Error at the opening/saving of scenario

Nonob Nonob

2013/9/30

#
Hi, I have this message from the terminal window of Greenfoot when I try to save or open a scenario. I tried uninstalling and reinstalling Greenfoot, Java SDK or Java and trying older version of Greenfoot but nothing works. I'm running on Windows 7 and on the 2.3.0 version of Greenfoot.
Exception in thread "AWT-EventQueue-0" java.lang.NullPointerException
	at com.sun.java.swing.plaf.windows.XPStyle.getTypeEnumName(XPStyle.java:155)
	at com.sun.java.swing.plaf.windows.XPStyle.getBorder(XPStyle.java:277)
	at com.sun.java.swing.plaf.windows.WindowsLookAndFeel$XPBorderValue.getXPValue(WindowsLookAndFeel.java:2403)
	at com.sun.java.swing.plaf.windows.WindowsLookAndFeel$XPValue.createValue(WindowsLookAndFeel.java:2358)
	at javax.swing.UIDefaults.getFromHashtable(UIDefaults.java:232)
	at javax.swing.UIDefaults.get(UIDefaults.java:162)
	at javax.swing.MultiUIDefaults.get(MultiUIDefaults.java:64)
	at javax.swing.UIDefaults.getBorder(UIDefaults.java:480)
	at javax.swing.UIManager.getBorder(UIManager.java:756)
	at javax.swing.border.TitledBorder.getBorder(TitledBorder.java:413)
	at javax.swing.border.TitledBorder.getBorderInsets(TitledBorder.java:348)
	at javax.swing.border.AbstractBorder.getBorderInsets(AbstractBorder.java:74)
	at javax.swing.JComponent.getInsets(JComponent.java:1824)
	at java.awt.FlowLayout.preferredLayoutSize(FlowLayout.java:434)
	at java.awt.Container.preferredSize(Container.java:1788)
	at java.awt.Container.getPreferredSize(Container.java:1773)
	at javax.swing.JComponent.getPreferredSize(JComponent.java:1662)
	at java.awt.BorderLayout.preferredLayoutSize(BorderLayout.java:719)
	at java.awt.Container.preferredSize(Container.java:1788)
	at java.awt.Container.getPreferredSize(Container.java:1773)
	at javax.swing.JComponent.getPreferredSize(JComponent.java:1662)
	at javax.swing.ViewportLayout.preferredLayoutSize(ViewportLayout.java:95)
	at java.awt.Container.preferredSize(Container.java:1788)
	at java.awt.Container.getPreferredSize(Container.java:1773)
	at javax.swing.JComponent.getPreferredSize(JComponent.java:1662)
	at javax.swing.ScrollPaneLayout.preferredLayoutSize(ScrollPaneLayout.java:492)
	at java.awt.Container.preferredSize(Container.java:1788)
	at java.awt.Container.getPreferredSize(Container.java:1773)
	at javax.swing.JComponent.getPreferredSize(JComponent.java:1662)
	at greenfoot.gui.GreenfootFrame$8.getPreferredSize(GreenfootFrame.java:502)
	at java.awt.BorderLayout.preferredLayoutSize(BorderLayout.java:719)
	at java.awt.Container.preferredSize(Container.java:1788)
	at java.awt.Container.getPreferredSize(Container.java:1773)
	at javax.swing.JComponent.getPreferredSize(JComponent.java:1662)
	at java.awt.BorderLayout.layoutContainer(BorderLayout.java:827)
	at java.awt.Container.layout(Container.java:1503)
	at java.awt.Container.doLayout(Container.java:1492)
	at java.awt.Container.validateTree(Container.java:1688)
	at java.awt.Container.validateTree(Container.java:1697)
	at java.awt.Container.validateTree(Container.java:1697)
	at java.awt.Container.validateTree(Container.java:1697)
	at java.awt.Container.validate(Container.java:1623)
	at java.awt.Container.validateUnconditionally(Container.java:1660)
	at java.awt.Window.show(Window.java:1033)
	at java.awt.Component.show(Component.java:1651)
	at java.awt.Component.setVisible(Component.java:1603)
	at java.awt.Window.setVisible(Window.java:1014)
	at greenfoot.core.GreenfootMain$2.run(GreenfootMain.java:227)
	at java.awt.event.InvocationEvent.dispatch(InvocationEvent.java:251)
	at java.awt.EventQueue.dispatchEventImpl(EventQueue.java:733)
	at java.awt.EventQueue.access$200(EventQueue.java:103)
	at java.awt.EventQueue$3.run(EventQueue.java:694)
	at java.awt.EventQueue$3.run(EventQueue.java:692)
	at java.security.AccessController.doPrivileged(Native Method)
	at java.security.ProtectionDomain$1.doIntersectionPrivilege(ProtectionDomain.java:76)
	at java.awt.EventQueue.dispatchEvent(EventQueue.java:703)
	at java.awt.EventDispatchThread.pumpOneEventForFilters(EventDispatchThread.java:242)
	at java.awt.EventDispatchThread.pumpEventsForFilter(EventDispatchThread.java:161)
	at java.awt.EventDispatchThread.pumpEventsForHierarchy(EventDispatchThread.java:150)
	at java.awt.EventDispatchThread.pumpEvents(EventDispatchThread.java:146)
	at java.awt.EventDispatchThread.pumpEvents(EventDispatchThread.java:138)
	at java.awt.EventDispatchThread.run(EventDispatchThread.java:91)
Exception in thread "AWT-EventQueue-0" java.lang.NullPointerException
	at com.sun.java.swing.plaf.windows.XPStyle.getTypeEnumName(XPStyle.java:155)
	at com.sun.java.swing.plaf.windows.XPStyle.getBorder(XPStyle.java:277)
	at com.sun.java.swing.plaf.windows.WindowsLookAndFeel$XPBorderValue.getXPValue(WindowsLookAndFeel.java:2403)
	at com.sun.java.swing.plaf.windows.WindowsLookAndFeel$XPValue.createValue(WindowsLookAndFeel.java:2358)
	at javax.swing.UIDefaults.getFromHashtable(UIDefaults.java:232)
	at javax.swing.UIDefaults.get(UIDefaults.java:162)
	at javax.swing.MultiUIDefaults.get(MultiUIDefaults.java:64)
	at javax.swing.UIDefaults.getBorder(UIDefaults.java:480)
	at javax.swing.UIManager.getBorder(UIManager.java:756)
	at javax.swing.border.TitledBorder.getBorder(TitledBorder.java:413)
	at javax.swing.border.TitledBorder.getBorderInsets(TitledBorder.java:348)
	at javax.swing.border.AbstractBorder.getBorderInsets(AbstractBorder.java:74)
	at javax.swing.JComponent.getInsets(JComponent.java:1824)
	at java.awt.FlowLayout.preferredLayoutSize(FlowLayout.java:434)
	at java.awt.Container.preferredSize(Container.java:1788)
	at java.awt.Container.getPreferredSize(Container.java:1773)
	at javax.swing.JComponent.getPreferredSize(JComponent.java:1662)
	at java.awt.BorderLayout.preferredLayoutSize(BorderLayout.java:719)
	at java.awt.Container.preferredSize(Container.java:1788)
	at java.awt.Container.getPreferredSize(Container.java:1773)
	at javax.swing.JComponent.getPreferredSize(JComponent.java:1662)
	at javax.swing.ViewportLayout.preferredLayoutSize(ViewportLayout.java:95)
	at java.awt.Container.preferredSize(Container.java:1788)
	at java.awt.Container.getPreferredSize(Container.java:1773)
	at javax.swing.JComponent.getPreferredSize(JComponent.java:1662)
	at javax.swing.ScrollPaneLayout.preferredLayoutSize(ScrollPaneLayout.java:492)
	at java.awt.Container.preferredSize(Container.java:1788)
	at java.awt.Container.getPreferredSize(Container.java:1773)
	at javax.swing.JComponent.getPreferredSize(JComponent.java:1662)
	at greenfoot.gui.GreenfootFrame$8.getPreferredSize(GreenfootFrame.java:502)
	at java.awt.BorderLayout.preferredLayoutSize(BorderLayout.java:719)
	at java.awt.Container.preferredSize(Container.java:1788)
	at java.awt.Container.getPreferredSize(Container.java:1773)
	at javax.swing.JComponent.getPreferredSize(JComponent.java:1662)
	at java.awt.BorderLayout.layoutContainer(BorderLayout.java:827)
	at java.awt.Container.layout(Container.java:1503)
	at java.awt.Container.doLayout(Container.java:1492)
	at java.awt.Container.validateTree(Container.java:1688)
	at java.awt.Container.validateTree(Container.java:1697)
	at java.awt.Container.validateTree(Container.java:1697)
	at java.awt.Container.validateTree(Container.java:1697)
	at java.awt.Container.validate(Container.java:1623)
	at java.awt.Window.dispatchEventImpl(Window.java:2717)
	at java.awt.Component.dispatchEvent(Component.java:4687)
	at java.awt.EventQueue.dispatchEventImpl(EventQueue.java:735)
	at java.awt.EventQueue.access$200(EventQueue.java:103)
	at java.awt.EventQueue$3.run(EventQueue.java:694)
	at java.awt.EventQueue$3.run(EventQueue.java:692)
	at java.security.AccessController.doPrivileged(Native Method)
	at java.security.ProtectionDomain$1.doIntersectionPrivilege(ProtectionDomain.java:76)
	at java.security.ProtectionDomain$1.doIntersectionPrivilege(ProtectionDomain.java:87)
	at java.awt.EventQueue$4.run(EventQueue.java:708)
	at java.awt.EventQueue$4.run(EventQueue.java:706)
	at java.security.AccessController.doPrivileged(Native Method)
	at java.security.ProtectionDomain$1.doIntersectionPrivilege(ProtectionDomain.java:76)
	at java.awt.EventQueue.dispatchEvent(EventQueue.java:705)
	at java.awt.EventDispatchThread.pumpOneEventForFilters(EventDispatchThread.java:242)
	at java.awt.EventDispatchThread.pumpEventsForFilter(EventDispatchThread.java:161)
	at java.awt.EventDispatchThread.pumpEventsForHierarchy(EventDispatchThread.java:150)
	at java.awt.EventDispatchThread.pumpEvents(EventDispatchThread.java:146)
	at java.awt.EventDispatchThread.pumpEvents(EventDispatchThread.java:138)
	at java.awt.EventDispatchThread.run(EventDispatchThread.java:91)
Exception in thread "AWT-EventQueue-0" java.lang.NullPointerException
	at com.sun.java.swing.plaf.windows.XPStyle.getTypeEnumName(XPStyle.java:155)
	at com.sun.java.swing.plaf.windows.XPStyle.getBorder(XPStyle.java:277)
	at com.sun.java.swing.plaf.windows.WindowsLookAndFeel$XPBorderValue.getXPValue(WindowsLookAndFeel.java:2403)
	at com.sun.java.swing.plaf.windows.WindowsLookAndFeel$XPValue.createValue(WindowsLookAndFeel.java:2358)
	at javax.swing.UIDefaults.getFromHashtable(UIDefaults.java:232)
	at javax.swing.UIDefaults.get(UIDefaults.java:162)
	at javax.swing.MultiUIDefaults.get(MultiUIDefaults.java:64)
	at javax.swing.UIDefaults.getBorder(UIDefaults.java:480)
	at javax.swing.UIManager.getBorder(UIManager.java:756)
	at javax.swing.border.TitledBorder.getBorder(TitledBorder.java:413)
	at javax.swing.border.TitledBorder.getBorderInsets(TitledBorder.java:348)
	at javax.swing.border.AbstractBorder.getBorderInsets(AbstractBorder.java:74)
	at javax.swing.JComponent.getInsets(JComponent.java:1824)
	at java.awt.FlowLayout.preferredLayoutSize(FlowLayout.java:434)
	at java.awt.Container.preferredSize(Container.java:1788)
	at java.awt.Container.getPreferredSize(Container.java:1773)
	at javax.swing.JComponent.getPreferredSize(JComponent.java:1662)
	at java.awt.BorderLayout.preferredLayoutSize(BorderLayout.java:719)
	at java.awt.Container.preferredSize(Container.java:1788)
	at java.awt.Container.getPreferredSize(Container.java:1773)
	at javax.swing.JComponent.getPreferredSize(JComponent.java:1662)
	at javax.swing.ViewportLayout.preferredLayoutSize(ViewportLayout.java:95)
	at java.awt.Container.preferredSize(Container.java:1788)
	at java.awt.Container.getPreferredSize(Container.java:1773)
	at javax.swing.JComponent.getPreferredSize(JComponent.java:1662)
	at javax.swing.ScrollPaneLayout.preferredLayoutSize(ScrollPaneLayout.java:492)
	at java.awt.Container.preferredSize(Container.java:1788)
	at java.awt.Container.getPreferredSize(Container.java:1773)
	at javax.swing.JComponent.getPreferredSize(JComponent.java:1662)
	at greenfoot.gui.GreenfootFrame$8.getPreferredSize(GreenfootFrame.java:502)
	at java.awt.BorderLayout.preferredLayoutSize(BorderLayout.java:719)
	at java.awt.Container.preferredSize(Container.java:1788)
	at java.awt.Container.getPreferredSize(Container.java:1773)
	at javax.swing.JComponent.getPreferredSize(JComponent.java:1662)
	at java.awt.BorderLayout.layoutContainer(BorderLayout.java:827)
	at java.awt.Container.layout(Container.java:1503)
	at java.awt.Container.doLayout(Container.java:1492)
	at java.awt.Container.validateTree(Container.java:1688)
	at java.awt.Container.validateTree(Container.java:1697)
	at java.awt.Container.validateTree(Container.java:1697)
	at java.awt.Container.validateTree(Container.java:1697)
	at java.awt.Container.validate(Container.java:1623)
	at java.awt.Window.dispatchEventImpl(Window.java:2717)
	at java.awt.Component.dispatchEvent(Component.java:4687)
	at java.awt.EventQueue.dispatchEventImpl(EventQueue.java:735)
	at java.awt.EventQueue.access$200(EventQueue.java:103)
	at java.awt.EventQueue$3.run(EventQueue.java:694)
	at java.awt.EventQueue$3.run(EventQueue.java:692)
	at java.security.AccessController.doPrivileged(Native Method)
	at java.security.ProtectionDomain$1.doIntersectionPrivilege(ProtectionDomain.java:76)
	at java.security.ProtectionDomain$1.doIntersectionPrivilege(ProtectionDomain.java:87)
	at java.awt.EventQueue$4.run(EventQueue.java:708)
	at java.awt.EventQueue$4.run(EventQueue.java:706)
	at java.security.AccessController.doPrivileged(Native Method)
	at java.security.ProtectionDomain$1.doIntersectionPrivilege(ProtectionDomain.java:76)
	at java.awt.EventQueue.dispatchEvent(EventQueue.java:705)
	at java.awt.EventDispatchThread.pumpOneEventForFilters(EventDispatchThread.java:242)
	at java.awt.EventDispatchThread.pumpEventsForFilter(EventDispatchThread.java:161)
	at java.awt.EventDispatchThread.pumpEventsForHierarchy(EventDispatchThread.java:150)
	at java.awt.EventDispatchThread.pumpEvents(EventDispatchThread.java:146)
	at java.awt.EventDispatchThread.pumpEvents(EventDispatchThread.java:138)
	at java.awt.EventDispatchThread.run(EventDispatchThread.java:91)
Nonob Nonob

2013/9/30

#
Ok the support told me what to do I tell you here how to solve this problem easily. You go to you Greenfoot installation folder, then you open the folder lib, then you find the file bluej.defs and you open it with the notepad. Here you will have a line where it's written : #bluej.lookAndFeel=crossplatform You have to erase the # from this line and then save. If it doesn't want to save on this folder, save it to your destkop and then copy your file into the lib folder. Now it should work !
You need to login to post a reply.