I asked Matlab Support and they told me I had to add it as a "shared resource and helper file" instead of adding it in the package tab. Now it works fine in the .exe
Sometimes the answers are soo simple and obvious...
Thanks Matlab Support!
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!