August 6th, 2002, 06:10 PM
|
#1 (permalink)
| | Ultimate Member
Join Date: Oct 2001
Posts: 21,019
|
Ok well I'm thinking it should be easy but hey what do I know?
All I want to do is execute a vbs script from another vbs script. The way I'm doing it now is "ok" but is a BIT cheesy
strCommandLine = strPath & "cscript NoExportAutoExport.vbs"
oWSHShell.Run(strCommandLine)  lol
How SHOULD I be executing the script?
I dont have a specific function in the script I just want to execute it and let her rip.
Any ideas?? |
| |
August 6th, 2002, 06:12 PM
|
#2 (permalink)
| | Thaumaturge Member
Join Date: Oct 2001 Location: West Haven, Utah
Posts: 12,671
|
Well, our resident VB expert Vass should be along in a minute to answer your question...
Doh!  |
| |
August 6th, 2002, 06:19 PM
|
#3 (permalink)
| | Ultimate Member
Join Date: Oct 2001
Posts: 21,019
|
Don't make me answer my own question  lol |
| |
August 6th, 2002, 06:32 PM
|
#4 (permalink)
| | Thaumaturge Member
Join Date: Oct 2001 Location: West Haven, Utah
Posts: 12,671
|
Well, since your code looks like greek to me, I'm not even going to attempt an answer. I'm mainly using VB in Access, and if I can get anything to work (cheesy or not) I consider myself lucky.  |
| |
August 6th, 2002, 06:46 PM
|
#5 (permalink)
| | Ultimate Member
Join Date: Oct 2001
Posts: 21,019
|
Hrrmmmm....
I seem to remember reading somewhere it was not possible...
But can you use the WScript object, when calling a script with cscript.exe (command line) instead of wscript.exe?
-- edit --
Ok already answered this particular question, yes you can still use the WSHShell object from within wscript.exe OR cscript.exe
The first question is still available for anybody to prove themselves worthy
Last edited by vass0922 : August 6th, 2002 at 07:02 PM.
|
| |
August 6th, 2002, 07:03 PM
|
#6 (permalink)
| | Senior Member
Join Date: Jul 2002 Location: London Suburbia,UK
Posts: 531
|
I thought you could, but then I'm only level 2 VB Prog, not 100% with VBScripting......
CBb |
| |
August 6th, 2002, 07:20 PM
|
#7 (permalink)
| | Ultimate Member
Join Date: Oct 2001
Posts: 21,019
| VB its easy to include COM objects, as well you can do so in VBS... however, its just a simple script that does not register with COM http://www.gammon.com.au/forum/bbsho...subject_id=726
Found some info, they include a method to do such at the bottom but they state there is no current way to "include" a new script. Damn scripting  lol |
| |
August 6th, 2002, 07:28 PM
|
#8 (permalink)
| | Senior Member
Join Date: Jul 2002 Location: London Suburbia,UK
Posts: 531
|
LOL
U and I need to talk sometime Vass, I need VB help a lot these days, and my poor ol head ( 28.5 (in Hex) yrs old ) don't always make it.
Hope to speak
CBB |
| |
August 6th, 2002, 07:31 PM
|
#9 (permalink)
| | Ultimate Member
Join Date: Oct 2001
Posts: 21,019
|
If you have a problem feel free to post it up, I'm not the only VB guy around here 
ALWAYS glad to see another developer down in these parts of the forums!!
Even if its not a how do I do this problem, but just a general fundamentals question of why does something do something.. feel free |
| |
August 6th, 2002, 07:38 PM
|
#10 (permalink)
| | Senior Member
Join Date: Jul 2002 Location: London Suburbia,UK
Posts: 531
|
TK Vass, sometimes I feel like the only VB fool in the UK.........
I post.......I ask......I beg / Implore..............
And folk come back with M$ Dev. Level Jargon which blows me!
I wil be sure to post all future VB Headaches here 1ST
TK again
CBB |
| | |
Currently Active Users Viewing This Thread: 1 (0 members and 1 guests) | | |
Posting Rules
| You may post new threads You may post replies You may not post attachments You may not edit your posts HTML code is Off | | | | Most Active Discussions | | | | | Recent Discussions  | | | | | |