& M+ F6 ^0 c% R7 ?$ W$ o3 u7 S- g* C/ d
Q: How do I open script files? Trying the above solution makes Windows XP throw an error?/ A( e! g3 F! B" u
& `3 H2 u) V: T2 j$ |
A:This is similar to the *.js association problem. Some machines seem to,for some reason, lose their *.vbs association. It's not that the filesopen with dreamweaver or whatever -- it's that the machine just doesn'tknow how to run them. If you have a scheduled task, "Could not run"will appear in the status column.- R# E, k( V e2 X! ~# m! c$ O* D
C$ N8 U* X! a1 P" E/ V% BSo, you're a smart person andread through the FAQ. You find the *.js extension problem, and you trythat fix: you run it as "wscript c:\path\to cript.vbs". But that, inturn, produces a pop-up error, this time a "Windows Scripting Host"error: "There is no script engine for file extension '.vbs'." So, forsome reason, wscript doesn't even know what to do with *.vbs files. 6 Q1 W. g8 P- g$ ~! X' ^% H 2 v4 u/ H; G5 l2 Q4 n8 U; kThe solution to this problem is to run the script as:, C" K/ ~# B% e7 F& W0 |: ?/ I
& u: ^0 }6 S4 a7 B, q# z; |4 qwscript //e:vbscript c:\path\to cript.vbs" j% h& D) F, A2 Q
, r7 b# q# [3 H" g; U
The "//e:vbscript" tells wscript to use the vbscript engine to parse the script. It will then run correctly.% _+ e# g i) [ p8 r8 y9 G
- O) q: R3 \; AA few alternative solutions, perhaps easier are: 0 W: R4 Q9 A1 O! D0 qRenameit .vbe (VBScript Encoded Script File). Not sure if this is a bad idea,but it seemed to work for some scripts. Make a new association for VBS.Open up my computer, select Tools menu-> Folder Options, and go tothe File Types tab. There probably isn't a VBS association listed ifyou have this problem. Select New, type in VBS, and hitAdvanced>>. Then, from the pull-down menu, select "VBScriptScript File". Making this selection automatically takes care of theassociation, along with the //e:vbscript problem. This is probably the"correct" solution... 7 w7 ~, @) }- `4 A G- t& [This problems usually occurs only on WindowsXP machines, but the cause is not known. A Microsoft KB article on thisissue can be found here. Thanks goes to Bob_2k for writing this FAQentry.