WScript don't run under Win95 ??? 
Author Message
 WScript don't run under Win95 ???

I have created a script that I call from a webpage using:

<!--
set Shell = Createobject("Wscript.Shell")
Shell.Run "c:\windows\cacp.vbe"
-->

The above line works under Windows 98 but not under 95.
Under 95 I get a message saying ;
Error: Active X component can't create object "Wscript.Shell"

I have loaded WSH 2.0 and Script Encoding.  Any Ideas???

BB



Sat, 14 Sep 2002 03:00:00 GMT  
 WScript don't run under Win95 ???
Win 95 can have trouble with registration of COM components. My first try would be to go to start, Run, and type REGSVR32   SCROBJ.DLL <enter> You will get a success report IF win 95 is NOT out of space in that part of the registry where com is registered. (64 K limit in win 95)

IF this is in fact what is happening, this link will help cleanup old entries.

"Failure Writing to the System Registry" Error Message When Running Setup Program Created Using Application Setup Wizard
http://support.microsoft.com/support/kb/articles/q247/4/97.asp

--
Mark L. Ferguson  Please reply in newsgroup
marfer's notes for OE 5 > http://www.geocities.com/SiliconValley/Bay/6386/IE_ng_notes.htm

Quote:

> I have created a script that I call from a webpage using:

> <!--
> set Shell = Createobject("Wscript.Shell")
> Shell.Run "c:\windows\cacp.vbe"
> -->

> The above line works under Windows 98 but not under 95.
> Under 95 I get a message saying ;
> Error: Active X component can't create object "Wscript.Shell"

> I have loaded WSH 2.0 and Script Encoding.  Any Ideas???

> BB



Sat, 14 Sep 2002 03:00:00 GMT  
 WScript don't run under Win95 ???
A couple more points:

A) You'll also want to regsvr32 wshom.ocx, as that's the file that actually
has WScript.Shell in it. If Mark's suggestion is the problem, you may have
many files that haven't been registered - reinstalling Script 5.1 may be in
order.

B) You are trying to run a vbe file from the command line. That doesn't work
in Win9x - you must explicitly call cscript or wscript to execute a script
file. On NT based systems, you can run script files without explicitly
calling the host, but not on 9x.

C) You also mention you are doing this from a web page. If Mark's suggestion
doesn't help, you might want to look at the security settings. Perhaps the
Win98 box has security set to low, and the Win95 box is set to normal or
high. From a security viewpoint, the shell.Run command is one of your more
dangerous commands (I'd say it's the most dangerous, in fact), hence the
shell object is not creatable from IE under default security.

Mike Whalen
Windows Script Dev



Win 95 can have trouble with registration of COM components. My first try
would be to go to start, Run, and type REGSVR32   SCROBJ.DLL <enter> You
will get a success report IF win 95 is NOT out of space in that part of the
registry where com is registered. (64 K limit in win 95)

IF this is in fact what is happening, this link will help cleanup old
entries.

"Failure Writing to the System Registry" Error Message When Running Setup
Program Created Using Application Setup Wizard
http://support.microsoft.com/support/kb/articles/q247/4/97.asp

--
Mark L. Ferguson  Please reply in newsgroup
marfer's notes for OE 5 >
http://www.geocities.com/SiliconValley/Bay/6386/IE_ng_notes.htm

Quote:
> I have created a script that I call from a webpage using:

> <!--
> set Shell = Createobject("Wscript.Shell")
> Shell.Run "c:\windows\cacp.vbe"
> -->

> The above line works under Windows 98 but not under 95.
> Under 95 I get a message saying ;
> Error: Active X component can't create object "Wscript.Shell"

> I have loaded WSH 2.0 and Script Encoding.  Any Ideas???

> BB



Sat, 14 Sep 2002 03:00:00 GMT  
 WScript don't run under Win95 ???
Ran what you suggested and got a message that it succeeded.
Any other ideas?

Thanks for your comments.
BB



Win 95 can have trouble with registration of COM components. My first try
would be to go to start, Run, and type REGSVR32   SCROBJ.DLL <enter> You
will get a success report IF win 95 is NOT out of space in that part of the
registry where com is registered. (64 K limit in win 95)

IF this is in fact what is happening, this link will help cleanup old
entries.

"Failure Writing to the System Registry" Error Message When Running Setup
Program Created Using Application Setup Wizard
http://support.microsoft.com/support/kb/articles/q247/4/97.asp

--
Mark L. Ferguson  Please reply in newsgroup
marfer's notes for OE 5 >
http://www.geocities.com/SiliconValley/Bay/6386/IE_ng_notes.htm

Quote:
> I have created a script that I call from a webpage using:

> <!--
> set Shell = Createobject("Wscript.Shell")
> Shell.Run "c:\windows\cacp.vbe"
> -->

> The above line works under Windows 98 but not under 95.
> Under 95 I get a message saying ;
> Error: Active X component can't create object "Wscript.Shell"

> I have loaded WSH 2.0 and Script Encoding.  Any Ideas???

> BB



Sat, 14 Sep 2002 03:00:00 GMT  
 WScript don't run under Win95 ???
You haven't answered the other query from Mike about using a command line, rather than an association for running the script.

shell.run "c:\windows\command\CScript.exe  c:\windows\cacp.vbe" ,  1,  true

or

shell.run "c:\windows\WScript.exe  c:\windows\cacp.vbe" ,  1,  true

A success in regsvr for the wshom.dll indicates you are NOT out of registry room.

--
Mark L. Ferguson  Please reply in newsgroup
marfer's notes for OE 5 > http://www.geocities.com/SiliconValley/Bay/6386/IE_ng_notes.htm

Quote:

> Ran what you suggested and got a message that it succeeded.
> Any other ideas?

> Thanks for your comments.
> BB



> Win 95 can have trouble with registration of COM components. My first try
> would be to go to start, Run, and type REGSVR32   SCROBJ.DLL <enter> You
> will get a success report IF win 95 is NOT out of space in that part of the
> registry where com is registered. (64 K limit in win 95)

> IF this is in fact what is happening, this link will help cleanup old
> entries.

> "Failure Writing to the System Registry" Error Message When Running Setup
> Program Created Using Application Setup Wizard
> http://support.microsoft.com/support/kb/articles/q247/4/97.asp

> --
> Mark L. Ferguson  Please reply in newsgroup
> marfer's notes for OE 5 >
> http://www.geocities.com/SiliconValley/Bay/6386/IE_ng_notes.htm


> > I have created a script that I call from a webpage using:

> > <!--
> > set Shell = Createobject("Wscript.Shell")
> > Shell.Run "c:\windows\cacp.vbe"
> > -->

> > The above line works under Windows 98 but not under 95.
> > Under 95 I get a message saying ;
> > Error: Active X component can't create object "Wscript.Shell"

> > I have loaded WSH 2.0 and Script Encoding.  Any Ideas???

> > BB



Sat, 14 Sep 2002 03:00:00 GMT  
 WScript don't run under Win95 ???
I had the same trouble running the bok examples. Then I found you had to
install IE4. First you must remove IE5 then install 4 with active desktop
options included, you don't have to keep them on, then re-install IE5.
Sems like a lot for something so basic but I tried everything else and this
is what finally did it.
Joe

Quote:
> Ran what you suggested and got a message that it succeeded.
> Any other ideas?

> Thanks for your comments.
> BB



> Win 95 can have trouble with registration of COM components. My first try
> would be to go to start, Run, and type REGSVR32   SCROBJ.DLL <enter> You
> will get a success report IF win 95 is NOT out of space in that part of
the
> registry where com is registered. (64 K limit in win 95)

> IF this is in fact what is happening, this link will help cleanup old
> entries.

> "Failure Writing to the System Registry" Error Message When Running Setup
> Program Created Using Application Setup Wizard
> http://support.microsoft.com/support/kb/articles/q247/4/97.asp

> --
> Mark L. Ferguson  Please reply in newsgroup
> marfer's notes for OE 5 >
> http://www.geocities.com/SiliconValley/Bay/6386/IE_ng_notes.htm


> > I have created a script that I call from a webpage using:

> > <!--
> > set Shell = Createobject("Wscript.Shell")
> > Shell.Run "c:\windows\cacp.vbe"
> > -->

> > The above line works under Windows 98 but not under 95.
> > Under 95 I get a message saying ;
> > Error: Active X component can't create object "Wscript.Shell"

> > I have loaded WSH 2.0 and Script Encoding.  Any Ideas???

> > BB



Fri, 20 Sep 2002 03:00:00 GMT  
 WScript don't run under Win95 ???
Does the Win95 box meet the documented minimum re: IE4 and DCOM95?  See the Windows Script 5.1
download page for exact details...

--
Michael Harris
MVP Scripting

I have created a script that I call from a webpage using:

<!--
set Shell = Createobject("Wscript.Shell")
Shell.Run "c:\windows\cacp.vbe"
-->

The above line works under Windows 98 but not under 95.
Under 95 I get a message saying ;
Error: Active X component can't create object "Wscript.Shell"

I have loaded WSH 2.0 and Script Encoding.  Any Ideas???

BB



Fri, 20 Sep 2002 03:00:00 GMT  
 
 [ 7 post ] 

 Relevant Pages 

1. WScript don't run under Win95 ???

2. WshShell.Run don't run WHY ???

3. PS fonts don't print in WIN95

4. PS fonts don't print in WIN95

5. i need help with 'wscript.run'

6. i need help with 'wscript.run'

7. Script don't run in Internet Explore

8. Running shortcut don't work on 2000?

9. HTA Files Don't Run Anymore

10. wshell.run arguments don't work

11. Functions don't run in server side javascript

12. WScript.GetObject doesn't get running Word App

 

 
Powered by phpBB® Forum Software