# Trying to create data type from selected with data types

**URL:** <https://forum.inductiveautomation.com/t/trying-to-create-data-type-from-selected-with-data-types/10010>\
**Category:** Ignition\
**Created:** [May 12, 2015, 9:18pm UTC](https://forum.inductiveautomation.com/t/trying-to-create-data-type-from-selected-with-data-types/10010 "2015-05-12T21:18:55Z")\
**Posts on this page:** 4\
**Page:** 1

<div class="post-metadata">

**Author:** ![fledder](https://avatars.discourse-cdn.com/v4/letter/f/e19b73/32.png) [@fledder](https://forum.inductiveautomation.com/u/fledder)\
**Post date:** [May 12, 2015, 9:18pm UTC](https://forum.inductiveautomation.com/t/trying-to-create-data-type-from-selected-with-data-types/10010/1 "2015-05-12T21:18:55Z")

</div>

Ignition 7.7.4 on Java 1.8.0\_45 on Windows 7  
I have a bunch of data types inside a folder, along with some plain tags. When I select the plain tags, right click, and choose "Create Data Type from Selected", I get a new data type editor, as expected. However, if my selection includes any instances of my other data type, and I do the same thing, I get an error mesage:

Message:

> [@](#):
>
> Error loading tags

Details:

[quote]java.lang.NullPointerException  
at com.inductiveautomation.ignition.common.sqltags.TagDefinition.setAttribute(TagDefinition.java:204)  
at com.inductiveautomation.ignition.common.sqltags.udt.ComplexTagDefinition.addTagMembersDeep(ComplexTagDefinition.java:385)  
at com.inductiveautomation.ignition.common.sqltags.udt.ComplexTagDefinition.createTypeFrom(ComplexTagDefinition.java:364)  
at com.inductiveautomation.ignition.designer.sqltags.action.TagsToUDTAction.actionPerformed(TagsToUDTAction.java:63)  
at javax.swing.AbstractButton.fireActionPerformed(Unknown Source)  
at javax.swing.AbstractButton$Handler.actionPerformed(Unknown Source)  
at javax.swing.DefaultButtonModel.fireActionPerformed(Unknown Source)  
at javax.swing.DefaultButtonModel.setPressed(Unknown Source)  
at javax.swing.AbstractButton.doClick(Unknown Source)  
at javax.swing.plaf.basic.BasicMenuItemUI.doClick(Unknown Source)  
at javax.swing.plaf.basic.BasicMenuItemUI$Handler.mouseReleased(Unknown Source)  
at java.awt.Component.processMouseEvent(Unknown Source)  
at javax.swing.JComponent.processMouseEvent(Unknown Source)  
at java.awt.Component.processEvent(Unknown Source)  
at java.awt.Container.processEvent(Unknown Source)  
at java.awt.Component.dispatchEventImpl(Unknown Source)  
at java.awt.Container.dispatchEventImpl(Unknown Source)  
at java.awt.Component.dispatchEvent(Unknown Source)  
at java.awt.LightweightDispatcher.retargetMouseEvent(Unknown Source)  
at java.awt.LightweightDispatcher.processMouseEvent(Unknown Source)  
at java.awt.LightweightDispatcher.dispatchEvent(Unknown Source)  
at java.awt.Container.dispatchEventImpl(Unknown Source)  
at java.awt.Window.dispatchEventImpl(Unknown Source)  
at java.awt.Component.dispatchEvent(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$1.doIntersectionPrivilege(Unknown Source)  
at java.security.ProtectionDomain$1.doIntersectionPrivilege(Unknown Source)  
at java.awt.EventQueue$4.run(Unknown Source)  
at java.awt.EventQueue$4.run(Unknown Source)  
at java.security.AccessController.doPrivileged(Native Method)  
at java.security.ProtectionDomain$1.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.7.4 (b2015033012)  
Java: Oracle Corporation 1.8.0\_45[/quote]

Not sure if I should be able to do this, but if I can't, a more explanatory error message would be nice.

---

<div class="post-metadata">

**Author:** ![Paolo.Mariani](https://sea1.discourse-cdn.com/inductiveautomation/user_avatar/forum.inductiveautomation.com/paolo.mariani/32/3285_2.png) [@Paolo.Mariani](https://forum.inductiveautomation.com/u/Paolo.Mariani)\
**Post date:** [June 5, 2015, 11:22pm UTC](https://forum.inductiveautomation.com/t/trying-to-create-data-type-from-selected-with-data-types/10010/2 "2015-06-05T23:22:40Z")

</div>

So creating a data type from a UDT instance should not be allowed, in the sense that if a UDT instance is selected, the option to create a data type should be grayed out and unselectable. This was found to be a bug, and a bug report has been filed for our developers to work into a future release.

---

<div class="post-metadata">

**Author:** ![Colby.Clegg](https://sea1.discourse-cdn.com/inductiveautomation/user_avatar/forum.inductiveautomation.com/colby.clegg/32/3282_2.png) [@Colby.Clegg](https://forum.inductiveautomation.com/u/Colby.Clegg)\
**Post date:** [June 10, 2015, 11:34pm UTC](https://forum.inductiveautomation.com/t/trying-to-create-data-type-from-selected-with-data-types/10010/3 "2015-06-10T23:34:27Z")

</div>

Hi,

Actually, I think in the relatively simple case you’re describing, this should work. You’ve just run into a very minor bug… once I fixed the error you hit, everything seemed to be fine. I think it will make it into 7.7.5 final, but I’ll have to post back when I know for sure.

Regards,

---

<div class="post-metadata">

**Author:** ![fledder](https://avatars.discourse-cdn.com/v4/letter/f/e19b73/32.png) [@fledder](https://forum.inductiveautomation.com/u/fledder)\
**Post date:** [June 11, 2015, 2:46am UTC](https://forum.inductiveautomation.com/t/trying-to-create-data-type-from-selected-with-data-types/10010/4 "2015-06-11T02:46:38Z")

</div>

Sounds great. Wasn’t a huge deal, but thought you guys would like to know. Thanks!
