# Error on first Window load in Designer: Unable to create new interface java.awt.Paint

**URL:** <https://forum.inductiveautomation.com/t/error-on-first-window-load-in-designer-unable-to-create-new-interface-java-awt-paint/30746>\
**Category:** Ignition\
**Created:** [December 16, 2019, 10:51pm UTC](https://forum.inductiveautomation.com/t/error-on-first-window-load-in-designer-unable-to-create-new-interface-java-awt-paint/30746 "2019-12-16T22:51:42Z")\
**Posts on this page:** 9\
**Page:** 1

<div class="post-metadata">

**Author:** ![nminchin](https://sea1.discourse-cdn.com/inductiveautomation/user_avatar/forum.inductiveautomation.com/nminchin/32/6911_2.png) [@nminchin](https://forum.inductiveautomation.com/u/nminchin)\
**Post date:** [December 16, 2019, 10:51pm UTC](https://forum.inductiveautomation.com/t/error-on-first-window-load-in-designer-unable-to-create-new-interface-java-awt-paint/30746/1 "2019-12-16T22:51:42Z")

</div>

I’m getting this error when I first open a Window up in the Designer. It happens to Windows that have particular templates contained in them, and the errors only show on the very first open of the Windows; if I close the window and open it again, there’re no errors. Wondering what would cause this?

 ![image](https://us1.discourse-cdn.com/inductiveautomation/original/2X/a/a8cac1454ded2484cb8075fd190bfa3a31497038.png)

---

<div class="post-metadata">

**Author:** ![Kevin.Herron](https://sea1.discourse-cdn.com/inductiveautomation/user_avatar/forum.inductiveautomation.com/kevin.herron/32/7259_2.png) [@Kevin.Herron](https://forum.inductiveautomation.com/u/Kevin.Herron)\
**Post date:** [December 16, 2019, 10:52pm UTC](https://forum.inductiveautomation.com/t/error-on-first-window-load-in-designer-unable-to-create-new-interface-java-awt-paint/30746/2 "2019-12-16T22:52:49Z")

</div>

Any chance of a full stack trace there?

---

<div class="post-metadata">

**Author:** ![nminchin](https://sea1.discourse-cdn.com/inductiveautomation/user_avatar/forum.inductiveautomation.com/nminchin/32/6911_2.png) [@nminchin](https://forum.inductiveautomation.com/u/nminchin)\
**Post date:** [December 16, 2019, 11:02pm UTC](https://forum.inductiveautomation.com/t/error-on-first-window-load-in-designer-unable-to-create-new-interface-java-awt-paint/30746/3 "2019-12-16T23:02:35Z")

</div>

Whoops, should have done that originally!

```auto
java.lang.ClassCastException: Unable to create new interface java.awt.Paint. java.awt.Paint
	at com.inductiveautomation.ignition.common.TypeUtilities$DefaultClassInitializer.createNew(TypeUtilities.java:1642)
	at com.inductiveautomation.ignition.common.TypeUtilities.getInitValueForClass(TypeUtilities.java:1593)
	at com.inductiveautomation.factorypmi.application.binding.AbstractPropertyAdapter.setQValue(AbstractPropertyAdapter.java:212)
	at com.inductiveautomation.factorypmi.application.binding.AbstractPropertyAdapter.updateValue(AbstractPropertyAdapter.java:259)
	at com.inductiveautomation.factorypmi.application.binding.ExpressionPropertyAdapter.runExpression(ExpressionPropertyAdapter.java:89)
	at com.inductiveautomation.factorypmi.application.binding.ExpressionPropertyAdapter.startup(ExpressionPropertyAdapter.java:113)
	at com.inductiveautomation.factorypmi.application.binding.DefaultInteractionController.startupBindings(DefaultInteractionController.java:355)
	at com.inductiveautomation.factorypmi.application.binding.DefaultInteractionController.startupAdapters(DefaultInteractionController.java:360)
	at com.inductiveautomation.factorypmi.application.components.template.VisionTemplate.startup(VisionTemplate.java:189)
	at com.inductiveautomation.factorypmi.application.components.template.TemplateHolder.startupTemplate(TemplateHolder.java:407)
	at com.inductiveautomation.factorypmi.application.components.template.TemplateHolder.onStartup(TemplateHolder.java:517)
	at com.inductiveautomation.vision.api.client.components.model.AbstractVisionPanel.startupComponent(AbstractVisionPanel.java:208)
	at com.inductiveautomation.factorypmi.application.components.util.ComponentVisitor$StartupVisitor.visit(ComponentVisitor.java:322)
	at com.inductiveautomation.factorypmi.application.components.util.ComponentVisitor.walk(ComponentVisitor.java:91)
	at com.inductiveautomation.factorypmi.application.components.util.ComponentVisitor.walk(ComponentVisitor.java:69)
	at com.inductiveautomation.factorypmi.application.FPMIWindow.startup(FPMIWindow.java:357)
	at com.inductiveautomation.factorypmi.designer.workspace.WindowWorkspace$DesigntimeWindowOpener.openWindow(WindowWorkspace.java:3554)
	at com.inductiveautomation.factorypmi.designer.workspace.WindowWorkspace.openWindow(WindowWorkspace.java:1322)
	at com.inductiveautomation.factorypmi.designer.model.navtree.WindowNode.onDoubleClick(WindowNode.java:269)
	at com.inductiveautomation.ignition.designer.navtree.NavTreePanel$MouseListener$1.run(NavTreePanel.java:719)
	at java.awt.event.InvocationEvent.dispatch(Unknown Source)
	at java.awt.EventQueue.dispatchEventImpl(Unknown Source)
	at java.awt.EventQueue.access$500(Unknown Source)
	at java.awt.EventQueue$3.run(Unknown Source)
	at java.awt.EventQueue$3.run(Unknown Source)
	at java.security.AccessController.doPrivileged(Native Method)
	at java.security.ProtectionDomain$JavaSecurityAccessImpl.doIntersectionPrivilege(Unknown Source)
	at java.awt.EventQueue.dispatchEvent(Unknown Source)
	at java.awt.EventDispatchThread.pumpOneEventForFilters(Unknown Source)
	at java.awt.EventDispatchThread.pumpEventsForFilter(Unknown Source)
	at java.awt.EventDispatchThread.pumpEventsForHierarchy(Unknown Source)
	at java.awt.EventDispatchThread.pumpEvents(Unknown Source)
	at java.awt.EventDispatchThread.pumpEvents(Unknown Source)
	at java.awt.EventDispatchThread.run(Unknown Source)

Ignition v7.9.10 (b2018112821)
Java: Oracle Corporation 1.8.0_221

```

---

<div class="post-metadata">

**Author:** ![lachguerabdallah](https://sea1.discourse-cdn.com/inductiveautomation/user_avatar/forum.inductiveautomation.com/lachguerabdallah/32/25558_2.png) [@lachguerabdallah](https://forum.inductiveautomation.com/u/lachguerabdallah)\
**Post date:** [October 14, 2020, 10:53am UTC](https://forum.inductiveautomation.com/t/error-on-first-window-load-in-designer-unable-to-create-new-interface-java-awt-paint/30746/4 "2020-10-14T10:53:33Z")

</div>

have you solved the problem? I have the same problem.

---

<div class="post-metadata">

**Author:** ![nminchin](https://sea1.discourse-cdn.com/inductiveautomation/user_avatar/forum.inductiveautomation.com/nminchin/32/6911_2.png) [@nminchin](https://forum.inductiveautomation.com/u/nminchin)\
**Post date:** [October 14, 2020, 10:54am UTC](https://forum.inductiveautomation.com/t/error-on-first-window-load-in-designer-unable-to-create-new-interface-java-awt-paint/30746/5 "2020-10-14T10:54:49Z")

</div>

Nope, I think I still get it on some pages. I just ignore it… 🤔

---

<div class="post-metadata">

**Author:** ![lachguerabdallah](https://sea1.discourse-cdn.com/inductiveautomation/user_avatar/forum.inductiveautomation.com/lachguerabdallah/32/25558_2.png) [@lachguerabdallah](https://forum.inductiveautomation.com/u/lachguerabdallah)\
**Post date:** [October 14, 2020, 10:59am UTC](https://forum.inductiveautomation.com/t/error-on-first-window-load-in-designer-unable-to-create-new-interface-java-awt-paint/30746/6 "2020-10-14T10:59:20Z")

</div>

are you using the active directory in your project?

---

<div class="post-metadata">

**Author:** ![nminchin](https://sea1.discourse-cdn.com/inductiveautomation/user_avatar/forum.inductiveautomation.com/nminchin/32/6911_2.png) [@nminchin](https://forum.inductiveautomation.com/u/nminchin)\
**Post date:** [October 14, 2020, 11:00am UTC](https://forum.inductiveautomation.com/t/error-on-first-window-load-in-designer-unable-to-create-new-interface-java-awt-paint/30746/7 "2020-10-14T11:00:52Z")

</div>

Nope. It’s something to do with colours. Doesn’t have anything to do with user security. I’m betting that it’s due to my use of client tags to store colour hex values and using them in bindings; when the page first loads, the client tags haven’t been read and therefore they’re nulls which colours don’t like

---

<div class="post-metadata">

**Author:** ![lachguerabdallah](https://sea1.discourse-cdn.com/inductiveautomation/user_avatar/forum.inductiveautomation.com/lachguerabdallah/32/25558_2.png) [@lachguerabdallah](https://forum.inductiveautomation.com/u/lachguerabdallah)\
**Post date:** [October 14, 2020, 11:17am UTC](https://forum.inductiveautomation.com/t/error-on-first-window-load-in-designer-unable-to-create-new-interface-java-awt-paint/30746/8 "2020-10-14T11:17:46Z")

</div>

Yes, you’re right, I just found out. I have component templates that have colors associated with tags where I have the colors stored. but in my case they are not clients tags.  
I have eliminated most of those errors.

---

<div class="post-metadata">

**Author:** ![paul-griffith](https://sea1.discourse-cdn.com/inductiveautomation/user_avatar/forum.inductiveautomation.com/paul-griffith/32/37249_2.png) [@paul-griffith](https://forum.inductiveautomation.com/u/paul-griffith)\
**Post date:** [October 14, 2020, 1:19pm UTC](https://forum.inductiveautomation.com/t/error-on-first-window-load-in-designer-unable-to-create-new-interface-java-awt-paint/30746/9 "2020-10-14T13:19:55Z")

</div>

The stacktrace you originally posted should be fixed in 8.0.14 and up - can you still reproduce?
