# Can't run exported application on Windows

**URL:** <https://discourse.processing.org/t/cant-run-exported-application-on-windows/38777>\
**Category:** Processing\
**Created:** [September 15, 2022, 3:53pm UTC](https://discourse.processing.org/t/cant-run-exported-application-on-windows/38777 "2022-09-15T15:53:44Z")\
**Posts on this page:** 5\
**Page:** 1

<div class="post-metadata">

**Author:** ![Eastern](https://yyz2.discourse-cdn.com/flex036/user_avatar/discourse.processing.org/eastern/32/13249_2.png) [@Eastern](https://discourse.processing.org/u/Eastern)\
**Post date:** [September 15, 2022, 3:53pm UTC](https://discourse.processing.org/t/cant-run-exported-application-on-windows/38777/1 "2022-09-15T15:53:44Z")

</div>

I’m currently using Processing 4.0.1 (Apple silicon version).  
It always shows “This application requires a Java Runtime Environment 17” when I try to open the exported application on Windows. Even after I download from [https://adoptium.net](https://adoptium.net/) as suggested in the export option menu, it still doesn’t work.

Does anyone know how to resolve this?

---

<div class="post-metadata">

**Author:** ![NumericPrime](https://yyz2.discourse-cdn.com/flex036/user_avatar/discourse.processing.org/numericprime/32/16318_2.png) [@NumericPrime](https://discourse.processing.org/u/NumericPrime)\
**Post date:** [September 15, 2022, 4:01pm UTC](https://discourse.processing.org/t/cant-run-exported-application-on-windows/38777/2 "2022-09-15T16:01:33Z")

</div>

I haven’t tried processing 4 yet but with 3 you have to check a box to embed Java. That might be the reason.

---

<div class="post-metadata">

**Author:** ![Eastern](https://yyz2.discourse-cdn.com/flex036/user_avatar/discourse.processing.org/eastern/32/13249_2.png) [@Eastern](https://discourse.processing.org/u/Eastern)\
**Post date:** [September 15, 2022, 4:16pm UTC](https://discourse.processing.org/t/cant-run-exported-application-on-windows/38777/3 "2022-09-15T16:16:43Z")

</div>

Mine says “Embed Java for Mac OS X”. Guess it won’t affect the windows version?

---

<div class="post-metadata">

**Author:** ![NumericPrime](https://yyz2.discourse-cdn.com/flex036/user_avatar/discourse.processing.org/numericprime/32/16318_2.png) [@NumericPrime](https://discourse.processing.org/u/NumericPrime)\
**Post date:** [September 15, 2022, 4:25pm UTC](https://discourse.processing.org/t/cant-run-exported-application-on-windows/38777/4 "2022-09-15T16:25:16Z")

</div>

That could be the reason. I had to export an application for Mac OS once (I use windows) so I sent it to a friend with a Mac to export it for me and send the data back.

Do you also have an IDE for base Java? If so you could compile it yourself. (I’ll look up how to do that)

1. Create a project in the IDE of your choice and put core.jar on your class-path which you should be able to find in your processing program folder \core\library. You should now do so with all your other libraries jar files. (these can usually be found under sketchbook/libraries/libraryName/library/libraryName.jar

2.You can look at the application.windows64 generated by export there in application.windows64/source you can find a java file with the same name as your sketch.

3.Create a new class with the same name as your sketch and copy the contents of the .java file you found in step 2.

4.Compile your projekt into a runnable jar file.

5.Wrap it into an .exe by e.g. using launch4j

[How To Convert JAR To .exe (Executable) By Using Launch4j | Wrap JAR Into EXE | JAR To EXE Easy Way - YouTube](https://www.youtube.com/watch?v=LpbQ-oTLsu0)

---

<div class="post-metadata">

**Author:** ![Eastern](https://yyz2.discourse-cdn.com/flex036/user_avatar/discourse.processing.org/eastern/32/13249_2.png) [@Eastern](https://discourse.processing.org/u/Eastern)\
**Post date:** [September 15, 2022, 7:38pm UTC](https://discourse.processing.org/t/cant-run-exported-application-on-windows/38777/5 "2022-09-15T19:38:06Z")

</div>

Thanks! Will try it later
