Quantcast
Channel: Adobe Community : Popular Discussions - Archived Discussions
Viewing all articles
Browse latest Browse all 21156

file for native process execution using environment variables

$
0
0

Hi.

 

I'm using the native process api in my air  program. Since this does not support the starting of batch files  directly, i have to start the cmd.exe instead and inside this, my batch  file. This works so far, but I have to use the absolut path  "c:\windows\system32\cmd.exe", which is not a good solution. Now I tried  to instantiate a new file object using one of the windows environmental  variables like "SystemRoot" or "windir", but i get the error "Error  #2004: One of the parameters is invalid. My code looks like this...

 

var f: File = new File("%SystemRoot%");

 

I tried some variations, but was not able to get this working. Is there any way to do this=

 

Regards

 

F.G.


Viewing all articles
Browse latest Browse all 21156

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>