# Import Java Class to the designer Ignition

**URL:** <https://forum.inductiveautomation.com/t/import-java-class-to-the-designer-ignition/19084>\
**Category:** General Discussion\
**Created:** [August 2, 2018, 10:16pm UTC](https://forum.inductiveautomation.com/t/import-java-class-to-the-designer-ignition/19084 "2018-08-02T22:16:49Z")\
**Posts on this page:** 5\
**Page:** 1

<div class="post-metadata">

**Author:** ![gabrielmatau](https://avatars.discourse-cdn.com/v4/letter/g/d2c977/32.png) [@gabrielmatau](https://forum.inductiveautomation.com/u/gabrielmatau)\
**Post date:** [August 2, 2018, 10:16pm UTC](https://forum.inductiveautomation.com/t/import-java-class-to-the-designer-ignition/19084/1 "2018-08-02T22:16:49Z")

</div>

Hi! everybody

i have a problem , wrote jar and need using in designer for ejecute in button by script, i have compile it and run de pack200 to generare of jar.pack.gz . place file in core/lib/commom also core/lib/designer but no work.

i try witch follow code

def Asterisk():  
from ignitionphone (this is mi package) import HelloManager (this is my class)  
originate = HelloManager().run  
call = Asterisk()

send this error

raceback (most recent call last):  
File “”, line 5, in  
File “”, line 2, in Asterisk  
ImportError: No module named ignitionphone

---

<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:** [August 2, 2018, 10:28pm UTC](https://forum.inductiveautomation.com/t/import-java-class-to-the-designer-ignition/19084/2 "2018-08-02T22:28:34Z")

</div>

Can you upload your JAR file somewhere for us to look at?

---

<div class="post-metadata">

**Author:** ![gabrielmatau](https://avatars.discourse-cdn.com/v4/letter/g/d2c977/32.png) [@gabrielmatau](https://forum.inductiveautomation.com/u/gabrielmatau)\
**Post date:** [August 2, 2018, 10:35pm UTC](https://forum.inductiveautomation.com/t/import-java-class-to-the-designer-ignition/19084/3 "2018-08-02T22:35:50Z")

</div>

Hi Kevin, thanks for you asnwer

[https://drive.google.com/open?id=1mpEwzzd9FfBdL1tmlNwgCXziHvvMkcEv](https://drive.google.com/open?id=1mpEwzzd9FfBdL1tmlNwgCXziHvvMkcEv)

This place both files on file!

regards!!

---

<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:** [August 2, 2018, 10:54pm UTC](https://forum.inductiveautomation.com/t/import-java-class-to-the-designer-ignition/19084/4 "2018-08-02T22:54:02Z")

</div>

Not only do you have additional jar files inside your jar file, which is not going to do what you’re hoping, you’ve placed your classes in a package called `ignition.phone.ignitionphone` rather than just `ignitionphone` like you’re referencing in the script.

---

<div class="post-metadata">

**Author:** ![gabrielmatau](https://avatars.discourse-cdn.com/v4/letter/g/d2c977/32.png) [@gabrielmatau](https://forum.inductiveautomation.com/u/gabrielmatau)\
**Post date:** [August 3, 2018, 2:04pm UTC](https://forum.inductiveautomation.com/t/import-java-class-to-the-designer-ignition/19084/5 "2018-08-03T14:04:09Z")

</div>

Hi Kevin! as they say here SOS UN CRAK 😃 , finally i see the class in designer, i now understand so so how work.

in my .jar missing a class java.util , i change de code python for this

def Asterisk():  
from ignition.phone.ignitionphone import HelloManager  
originate = HelloManager().run

call = Asterisk()

as send

line 2, in Asterisk  
java.lang.NoClassDefFoundError: org/asteriskjava/manager/action/ManagerAction

Thanks Bro!!!
