You can use the Shell function, according to my ancient VB 3.0 manual:
Dim TaskId, Style
TaskId = Shell ("perlscript.bat", Style)
Simple? However:
* You should also code an On Error in case VB can't run/find perlscript.bat.
* 'Style' is a number 1-9 depending on how you want to run it. 1=normal with
focus, 2=minimized with focus, 3=maximized with focus, 4=normal w/o focus,
6=minimized w/o focus. Check the Microsoft web site under VB / MSDN for more
info.
* The process runs asynchronously - and I don't think VB has a 'wait'
command.
Of course, all this could have changed in the past 8 years...
-----Original Message-----
From: Michael Carmody [mailto:[EMAIL PROTECTED]]
Sent: Wednesday, 08 August, 2001 22:22
To: [EMAIL PROTECTED]
Subject: A little off topic.
Having crafted my masterpiece in perl, I now need to get it to run from
within a VB script.
(VB takes office file, converts to .csv, which perl scripts then parses,
but poor secretary has to have excel doco to work on....)
So this is only in the interest of allowing perl to actually be used at my
work in a real environment (as opposed to only me using when I need it)
and being seen as a REAL tool, even though it's free/open source/not
microsoft
So how do i get visual basic to call external executable files ?
Such as perlscript.bat containing "perl myscript.pl"
Any help doubly appreciated...
Michael Carmody
MDU, Public Health Lab
Dept. of Microbiology and Immunology
The University of Melbourne, Parkville
--
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]