Scripts
 
Forums: » Register « |  User CP |  Games |  Calendar |  Members |  FAQs |  Sitemap |  Support | 
User Name:
Password:
Remember me
Go Back   Dev Shed ForumsWeb Site ManagementScripts

Reply
Add This Thread To:
  Del.icio.us   Digg   Google   Spurl   Blink   Furl   Simpy   Y! MyWeb 
Thread Tools Search this Thread Rate Thread Display Modes
 
Unread Dev Shed Forums Sponsor:
Stop making mediocre tutorials.The best tutorials are video! Camtasia Studio makes it easy to create engaging, buzz-building screen videos at any size, in any popular format. Download the free trial!
  #1  
Old March 18th, 2004, 05:17 PM
rhpos rhpos is offline
Contributing User
Dev Shed Newbie (0 - 499 posts)
 
Join Date: Jun 2003
Location: Midwest
Posts: 93 rhpos User rank is Just a Lowly Private (1 - 20 Reputation Level) 
Time spent in forums: 23 h 17 m 29 sec
Reputation Power: 6
Calling wsh module fron web page

I try calling/running a vbs script from a web page on a
Win2K workstation with the following code:

<input type="BUTTON" name="Exec1" value="Run me" language="vbs" onclick="version">
<script language="vbs">
Sub version
Dim WshShell
Set WshShell = CreateObject("WScript.Shell")
WshShell.Run "c:\WSH Script\WSHversion.vbs"
Set WshShell = Nothing
End Sub
</script>

Error returned:
The system cannot find the file specified.

I can put the identical code in a .vbs file and it seems
to work properly, but only if the .vbs to be run (WSHversion.
vbs in this case) is in the same directory as the calling
.vbs.

Is it impossible to run a separate vbs script from within
a web browser? I have seen several examples where
separate Windows programs (CMD, notepad, .bat files)
are run within browser script using essentially the same
code as above.

I have already checked my path variable which contains
a C:\ reference. I cannot think of what else might be
wrong.

Would I essentially have to put the actual code of the
script I want run in the web page instead of trying to
call it?

Reply With Quote
Reply

Viewing: Dev Shed ForumsWeb Site ManagementScripts > Calling wsh module fron web page


Thread Tools  Search this Thread 
Search this Thread:

Advanced Search
Display Modes  Rate This Thread 
Rate This Thread:


Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off
View Your Warnings | New Posts | Latest News | Latest Threads | Shoutbox
Forum Jump


Forums: » Register « |  User CP |  Games |  Calendar |  Members |  FAQs |  Sitemap |  Support | 
  
 





© 2003-2008 by Developer Shed. All rights reserved. DS Cluster 3 hosted by Hostway