Using the ActiveX Object "Excel.Application" from JScript

U

UnaCoder

Hi, I noticed that this particular object is only accessable if the IE
security setting "Initialize and and script ActiveX controls not marked
as safe" is enabled. Does windows maintain this list somewhere? Is it
hard coded, or can you edit it?

Also, is there a way for the script to ask the user if they want to
change the security setting to allow the ActiveX control to be used?

For example, if "Initialize and script ..." is marked Disabled, and you
catch this exception trying to setup the ActiveX object, can the script
tell IE to ask the user to enable the security setting with a dialog
box allowing the user to click "yes" to enable to setting, or "no" to
deny it?
 
R

Randy Webb

UnaCoder said the following on 4/21/2006 12:33 PM:
Hi, I noticed that this particular object is only accessable if the IE
security setting "Initialize and and script ActiveX controls not marked
as safe" is enabled. Does windows maintain this list somewhere? Is it
hard coded, or can you edit it?

What object?

Is there a list? Why would it need to keep a list of unauthorized
ActiveX controls? It would keep a list of allowed ones though.
Also, is there a way for the script to ask the user if they want to
change the security setting to allow the ActiveX control to be used?

Is your name Soren by chance?

But no, the user has told the browser "Don't do this" and you are
wanting to ask them "Hey, you don't want to do this but would you change
that setting and do what you said you didn't want to do to start with?"
For example, if "Initialize and script ..." is marked Disabled, and you
catch this exception trying to setup the ActiveX object, can the script
tell IE to ask the user to enable the security setting with a dialog
box allowing the user to click "yes" to enable to setting, or "no" to
deny it?

Script resetting browser settings? Absolutely *NO*. You can't set
browser settings via script. You aren't allowed to change settings of
the browser via script. Did I mention that you can't change my browser
settings via script?

try{
//try to activate ActiveX
}
catch(e){
//error handling
alert('If you are completely stupid enough, would you give me access to
your computer via my unsafe ActiveX component please?')
}

BTW, did I mention that you can't change browser settings with script?
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

Forum statistics

Threads
473,777
Messages
2,569,604
Members
45,226
Latest member
KristanTal

Latest Threads

Top