|
|
|
#1 |
|
Registered User
Join Date: Oct 2011
Posts: 9
|
Hello, I've a problem with the function "ssCore.Layout.loadFile"
I've a button with that code : Code:
on (release){
var return_obj = ssCore.Layout.loadFile({resource:"batch.exe"});
ssCore.Shell.execute(return_obj.result);
ssCore.App.quit();
}
I've had the batch.exe file in the Resources like that : [-] Layout |__ [+] batch.exe Movie Tab : "use the auto-extract folder" I think the problem comes from "resource:"batch.exe"" or/and "return_obj.result"... ? Thanks for your help. Ps : sorry for my bad english |
|
|
|
|
|
#2 |
|
Plugin Developer
Join Date: Jun 2002
Location: Germany
Posts: 2,409
|
You´re quite off the track here.
If you want to simply execute the exe this will be enough, if you have set the file to auto-extract on the Layout tab ActionScript Code:
no need to load anything. Read the docs on the methods to get to know what they do. |
|
|
|
|
|
#3 |
|
Registered User
Join Date: Oct 2011
Posts: 9
|
Thank for your reply
Code:
ssCore.Shell.execute({path:"tempdir://batch.exe"});
Code:
ssCore.Shell.execute({path:ssGlobals.ssTempDir + "\\batch.exe"});
|
|
|
|
|
|
#4 |
|
Tim
Join Date: May 2001
Location: Ottawa
Posts: 11,873
|
When you add files to the Files Tab they are marked as "auto extract" (to the temp folder) by default. If you change them to "no auto extract" then you have to extract the file manually before you can use Shell.execute on it.
|
|
|
|