BuzzDee
hi!
i tried my vbscripts on another pc but i always get the error message:


----------------------------------
Windows Script Host

Skriptmodul `VBSkript` fuer Skript `c:\_path_\test.vbs` wurde nicht gefunden

`OK` -> Button
----------------------------------

since its german a little transaltion - hope it wont be too bad^^ :

sciptmodule `vbscript` for script `c:\_path_\test.vbs` could not be found



whats wrong??

thx buzz
w00dy
the module vbscript is not in the same location (path) in relation to the vbs. You have to copy over the missing module to the other computer and then readd it to the vbs, or you add the missing module and the vbs to the exact same path as it is on the original computer.
BuzzDee
hmm im not sure about what u mean with vbscript module... whats that? is it a program? or a dll?
w00dy
All the files u included in your script, as well as the script itself, must be in the same path as it is on the original computer. The paths are absolute, not relative.
IE
If u make a app and it uses these files
C:\app\script.vbs
C:\app\script2.vbs
C:\dll\bleh.dll

When u copy it to a new computer, the file structure must remain the same.
You cant have
C:\blah\script.vbs
C:\blah\script2.vbs
C:\blah\bleh.dll
BuzzDee
ok but my script is very simple and only includes scan.txt and fp30reg.exe. these files are in the same folder as the vbs file.

heres my script:

Set objFSO = CreateObject("Scripting.FileSystemObject")
Set objTextFile = objFSO.OpenTextFile("scan.txt",1)
Do Until objTextFile.AtEndOfStream
strip = objTextFile.Readline
runstr = "fp30reg.exe " & strip & " "
dim wsh
set wsh = CreateObject("WScript.Shell")
wsh.run(runstr)
Loop

on my other pc i can run the three files together in every directory i want to...

the strange thing is that EVERY vbscript on my pc shows that error. even those which are scripts belonging to the system!

i think there must be sth else wrong....
Yorn
The machine that you are attempting to run the scripts on has any of the following issues:

1) It is not XP/2k
2) Scripting services are disabled (sounds to be most likely cause)
3) Locked on Cscript for default, but if you ran the vbs it should know that your not using Cscript.

Your problem has pretty much gotta be #2. I forgot how to turn scripting services back on

This is a "lo-fi" version of our main content. To view the full version with more information, formatting and images, please click here.

 
Invision Power Board © 2001-2005 Invision Power Services, Inc.