Jump to content
Sign in to follow this  
Olish

Including an executable?

Recommended Posts

Olish

Is including an executable possible before compiling the script?

By example, to protect the execution of an executable by a password like this:

$passwd = InputBox("Security Check", "Enter your password.", "", "*")

If $passwd="toto" Then CODE FOR INCLUDING AN EXECUTABLE

Olivier, from France.Free Wake On LAN script

Share this post


Link to post
Share on other sites
greenmachine

Well you can use FileInstall() to include the executable (it includes it in the exe on compile regardless), and then use your InputBox idea to tell whether to place the included exe onto the user's computer.

In other words:

$passwd = InputBox("Security Check", "Enter your password.", "", "*")

If $passwd="toto" Then
    FileInstall ("C:\Direct\Path\To\File.exe", $NewFilePathThatCanBeAVariable, $FlagThatIs1ToOverWriteExistingFiles)
Endif

The flag is optional - default is 0 (don't overwrite).

Edited by greenmachine

Share this post


Link to post
Share on other sites
Olish

Ok. If I understand good, I can make an "home made" installer including the files in the compiled script, which script installs the files in the directory precised by $NewFilePathThatCanBeAVariable ???


Olivier, from France.Free Wake On LAN script

Share this post


Link to post
Share on other sites
MHz

Ok. If I understand good, I can make an "home made" installer including the files in the compiled script, which script installs the files in the directory precised by $NewFilePathThatCanBeAVariable ???

Yes, you can do that. :lmao:

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
Sign in to follow this  

×

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.