ActiveXObject("Shell.Application")

  • Thread starter Thread starter Guest
  • Start date Start date
G

Guest

Hi there,

I want to use javacript in my ASPX page, using ActiveX (
ActiveXObject("Shell.Application"); ) to call external application.

How I know if the IExplorer settings for ActiveX is enabled ? Any helper
javascript class for do it ?

Any help will be appreciated, and I will be very grateful.

Thanks in advanced, greetings

The code is the following
<SCRIPT type="text/javascript" LANGUAGE="JavaScript">
function executeCommands()
{
var oShell = new ActiveXObject("Shell.Application");
var commandtoRun = "C:\\program1.exe ";
oShell.ShellExecute(commandtoRun, "/INI=param1.ini",
"", "open", "1");
}
</SCRIPT>
 
this won't work. only safe active/x controls can be created in the browser.

-- bruce (sqlwork.com)
 
How I know if the IExplorer settings for ActiveX is enabled ? Any helper
javascript class for do it ?

Not as far as I know...

HttpContext.Current.Request.Browser.ActiveXControls will tell you whether
the browser is "capable" of supporting ActiveX, but not whether this has
been enabled or disabled...
 
Why do you need that functionality? The web page will try to open an
application on the end-user machine. Is that your intention? Or you want it
to open the application on the server? This is frequently confused in here.

--
Regards,
Alvin Bruney
------------------------------------------------------
Shameless author plug
Excel Services for .NET is coming...
https://www.microsoft.com/MSPress/books/10933.aspx
OWC Black Book www.lulu.com/owc
Professional VSTO 2005 - Wrox/Wiley
 
Back
Top