Solved

Executing VBScript

Posted on 2007-03-29
5
1,290 Views
Last Modified: 2008-01-09
How do you execute a VBScript application in Windows XP Pro?  When I double-click the file; the file is opened up with notepad.
0
Comment
Question by:Ray Turner
5 Comments
 
LVL 15

Expert Comment

by:JackOfPH
ID: 18821550
http://www.experts-exchange.com/Programming/Languages/Visual_Basic/Q_21982231.html

Visit the link, I think it may help you... post if you have questions
0
 
LVL 14

Accepted Solution

by:
Burns2007 earned 250 total points
ID: 18821552
Is it saved as a .vbs extension? If so, someone has changed the association.

Right click on it and go open with.
If it is there under recommended, select "Microsoft Windows Based Script Host" and tick Always use the selected...

If it is not there in the list, you'll have to click on browse and go to "C:\WINDOWS\System32\WScript.exe"
0
 
LVL 15

Assisted Solution

by:JackOfPH
JackOfPH earned 250 total points
ID: 18821562
Try this step:

Go to Windows explorer window, choose Folder options from the Tools menu, then clicking on the File Types tab.  Scroll down until you see VBS, then highlight it and click on the Restore button.

0
 
LVL 12

Expert Comment

by:viralypatel
ID: 18821602
has already been answered somewhere ...

here is it again for ur reference

You can change the file association back by opening a Windows explorer window, choosing Folder options from the Tools menu, then clicking on the File Types tab.  Scroll down until you see VBS, then highlight it and click on the Restore button - this will set it back to its default options.

If you want to edit teh file rather than run it, right click on the file and choose Edit from the popup menu, not Open.  It will automatically open it in Notepad for you
0
 
LVL 5

Expert Comment

by:WesleySaysHi
ID: 18821795
In order to run your VBScript file by double-clicking the file, you need the Windows Script Host. You can find refferences here:
http://www.microsoft.com/resources/documentation/windows/xp/all/proddocs/en-us/sag_wshtopnode.mspx

Windows Script Host is part of Internet Explorer and you should have it. In case that something happened to it, then go at: http://support.microsoft.com/kb/188135 and see the links listed under "On This Page". You will se there a title called: "Installing Windows Script Host"

The file association problem has been discussed here, therefore I will not mention it any more.

There is also a command line version of the Windows Script Host: CSCript.exe about which you can find refferences at the address below, just in case you're interested: http://www.microsoft.com/resources/documentation/windows/xp/all/proddocs/en-us/cscript_overview.mspx?mfr=true

Wesley
0

Featured Post

Active Directory Webinar

We all know we need to protect and secure our privileges, but where to start? Join Experts Exchange and ManageEngine on Tuesday, April 11, 2017 10:00 AM PDT to learn how to track and secure privileged users in Active Directory.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

A short article about a problem I had getting the GPS LocationListener working.
If you’re thinking to yourself “That description sounds a lot like two people doing the work that one could accomplish,” you’re not alone.
This lesson covers basic error handling code in Microsoft Excel using VBA. This is the first lesson in a 3-part series that uses code to loop through an Excel spreadsheet in VBA and then fix errors, taking advantage of error handling code. This l…

830 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question