The best way to do this is you can downlaod community commons module and use the Java Action FileFromFileDocumet
Hope this helps!
Sorry for digging this up.
I have need to save a file to local directory and use FileFromFileDocument too. It work on my local computer. But when I deploy to acceptance ( cloud environment ), It give the following error :
ERROR - Connector: com.mendix.modules.microflowengine.MicroflowException: com.mendix.systemwideinterfaces.MendixRuntimeException: java.io.FileNotFoundException: ServiceAccountKey.json (Permission denied) 2021-03-04T04:16:52.553053 [APP/PROC/WEB/0] at IngredientsMasterMaintenance.ACT_saveKeyFile (JavaAction : 'File from file document')
How can I resolve this ? Please this is urgent .
Yes! it worked, thank you so much