mendenaresh1357 - Sunday, June 6, 2010 10:39 AM:
Hi All,
How to run a .exe file from aras. Both from client and Server side.
Naresh.
Yoann Maingon - Sunday, June 6, 2010 11:12 AM:
Hi,
This is more a technology question than an Aras question.
So the question is more "how to start an app from a webapp (server side) and webpage(client side)".
From the server, you'll be able to start apps which are on your server (using vb or c#)
From the Client, you can start apps on your client. You can do that by calling activex from javascript or maybe with a java applet.
Yoann
www.prodeos.com
mendenaresh1357 - Sunday, June 6, 2010 12:22 PM:
Hi Yaonn,
What you said is correct. But i used methods which usually runs Exe file (outside aras).
BLOCKED SCRIPT
var MyObject = new ActiveXObject("WScript.Shell");
if(!MyObject)
{
alert("MyObject Not Created");
}
else
{
MyObject.Run("file:///C:/WindowsApplication1.exe");
}
return true;
C#
System.Diagnostics.Process.Start("C:WindowsApplication1.exe");
return this;
Neither of this works from aras. If you have any sample code which Runs EXE file from "Aras" will be helpful.
Naresh
Yoann Maingon - Sunday, June 6, 2010 1:06 PM:
Naresh,
have you allowed the activex for the trusted sites on IE?
Is this exact code working outside Aras as you said ? (just to check if you have no syntax issue [ myobject.run('"C:\WindowsApplication1.exe"); ]
Until now I usally work with the application ActiveX directly. It gives you access to the COM interface if it exposes any.
Our light office connector should be published soon on the Aras Project.
Most of our project are developped openly on our codeplex page : http://prodeos.codeplex.com/
Feel free to join.
Yoann
parepalli - Sunday, May 12, 2013 10:23 PM:
Hi Naresh
I also have the same question. Did you find the solution?
Thanks in advance
biztram - Thursday, August 8, 2013 9:05 AM:
Hey,
I've got the same problem and i might wonder if the issue isn't solved yet.
I also want to execute an exe in the aras vault from client side with Java. To confirm that there is no problem
with my ActiveX-Settings i executed a method via button with an "OneClickEvent" including:
var word = new ActiveXObject("Word.Application");
It works fine, Word started.
With a third program.exe unfornutaley nothing happened. I tried much variations of Naresh's code e.g. different Path-Variables, "new ActiveObject("Shell.Application");" , "myObject.ShellExecute("mypath")" instead of "myObject.Run("mypath)" and so on.
- but nothing worked.
Thanks in advance!
Best regards,
biztram
biztram - Saturday, August 10, 2013 8:13 AM:
I just wanted to say that the problem is solved: The code of Naresh is working.
Beside setting the right marks for IE trusted sites settings the following action is required:
Allow Active Content to run files
Tools > Internet Options > Advanced > Security Enable "Allow Active Content to run in files on My Computer"
Best regards,
biztram
[email protected] - Monday, August 12, 2013 4:24 PM:
Hello,
please be aware that you could have a security issue within this solution. Running local scripts or exe files from Internet explorer could open a "hole" where other internet websites are able to run local programs - e.g. even do a cmd.exe and run an "del *.*".
The ActiveX option is better - but also risky regarding security.
// Jens
NTTDATA Germany GmbH