Any info is greately appreciated.
--
soler
AutoIt
--
Microsoft MVP -- ASP/ASP.NET
Please reply to the newsgroup. The email account listed in my From
header is my spam trap, so I don't check it very often. You will get a
quicker response by posting to the newsgroup.
hi Soler,
There are several ways to do this, but none of them are
entirely satisfactory. If God had intended for a script
to be an exe, then microsoft would have provided it.
Way One. Use the Admin Script Editor" product, which
has a "packager feature" (formerly called vbScript-to-Exe).
http://www.adminscripteditor.com/editor/scriptpackager/
You are going to have to pay for ASE, but it is probably
the quickest way to what you want.
Way Two. If you wait around a bit, mayayana will probably
come along and recommend an "installer" product (Power
Archiver). There are any number of installers out there,
some for sale and some free, and you can use them to wrap
up your script into an exe, along with instructions on
how to "install" your script (unwrap and place on a target
system).
Way Three. This is the "roll-yer-own" approach. Get
yourself a vb (classic) compiler, and a copy of microsoft's
"windows script control":
The idea here is that the script control can run your script
INSIDE an exe. So you compile an exe with the script control
instantiated. In your program, you can load your script into
the script control, and then execute it. You may include the
script in your exe (program) as a text array, or if you want
to get fancy, as a text "resource" (which you compile into
a "resource file" with microsoft's resource compiler (rc.exe).
There is an example of this posted previously in this ng.
There are other approaches. If you go to Google's Advanced
Group Search:
http://groups.google.com/advanced_search
and type "vbs to exe" into the search engine, you will get
several pages of hits.
As was previously mentioned, your best bet is to convert the
vbScript to another language that supports compiling (or
wrapping) into an exe (for example: autoit, FBSL, o'Basic,
RapidQ, etc). Also, if you can get a copy of a "classic" vb
compiler (vb5/6) and convert your vbs into vb, then you can
compile directly to an exe.
cheers, jw
____________________________________________________________
You got questions? WE GOT ANSWERS!!! ..(but,
no guarantee the answers will be applicable to the questions)
> Way Three. This is the "roll-yer-own" approach. Get
> yourself a vb (classic) compiler, and a copy of microsoft's
> "windows script control":
>
> http://www.microsoft.com/downloads/details.aspx?familyid=D7E31492-2595-49E6-8C02-1426FEC693AC&displaylang=en
>
> The idea here is that the script control can run your script
> INSIDE an exe. So you compile an exe with the script control
> instantiated. In your program, you can load your script into
> the script control, and then execute it. You may include the
> script in your exe (program) as a text array, or if you want
> to get fancy, as a text "resource" (which you compile into
> a "resource file" with microsoft's resource compiler (rc.exe).
> There is an example of this posted previously in this ng.
I use the MSScriptControl inside a Delphi DLL... Having said that, you can
download the free version of Delphi Turbo which allows you to do everything the
paid version does, except that it doesn't allow for the installing of 3rd party
components on the component palette. I am only mentioning this as an
alternative because the structure of Pascal is not so overwhelming (and a legal
copy of VB6 is getting harder to find) that this small program couldn't be made
to happen pretty quickly.
You can put you vbScript in a Res file and include it pretty easily.
What are you trying to accomplish by converting to .exe?
If you just want to keep your casual users from altering your script code,
encoding to a .vbe is sufficient. I use a script which I just drop .vbs
files on and have a .vbe created automagically.
--
Todd Vargo
(Post questions to group only. Remove "z" to email personal messages)
It works fine. I've done it with Power Archiver.
Most zip programs that can create an SFX can
take a command line, so one can put a number of
files into the zip, set script.vbs as command
line, convert it to EXE, then set it all to unpack
into the TEMP folder and run from there. (I actually
package software installations that way as well.)
Best regards
Sylv1
Best regards
Sylv1
maybe i have a problem
then,
to convert VBS to EXE , I use vbs to exe
you an download it on :
http://www.f2ko.de/English/v2e/index.php
But it does not run with js script.
Best regards