Computing.Net > Forums > Programming > Disable editing a batch file

Computer Problems? Computing.Net has over 1,000,000 posts about all things technology related! Over 90% answered within 24 hours! Click here to start participating now! Also, be sure to check out the New User Guide.

Disable editing a batch file

Reply to Message Icon

Name: ZAB
Date: September 1, 2008 at 11:22:09 Pacific
OS: XP
CPU/Ram: -
Product: 2400
Comment:

Hey, I just wrote a batch file, but i dont want people to go into notepad and edit the file. I still want the file to run, but i dont want i to be editied. Help me?



Sponsored Link
Ads by Google

Response Number 1
Name: Razor2.3
Date: September 1, 2008 at 18:40:38 Pacific
Reply:

Can't. If you want something hard to change, pick up a language with a complier.


0

Response Number 2
Name: IVO
Date: September 2, 2008 at 01:14:12 Pacific
Reply:

A very raw way (and effective for dumb people only) is to set the batch file attributes to read-only and hidden. Store the file then issue

attrib +R +H File_Name

The batch still can run but is stealth and not editable.


0

Response Number 3
Name: Judago
Date: September 2, 2008 at 01:23:14 Pacific
Reply:

There are some batch file "compilers" out there. A google search of "batch compiler" will bring up many.

Most of them just compress a text file and make an executable that essentially is a self extractable archive that contains a text file and a stub of code that runs the text as a batch file with cmd.exe. The text file is extracted to a temporary directory and is run from there.

If your trying to hide your "secret code" or passwords, ect. It would still be accessible to anyone savy enough, though in an uncompresed form in a temporary directory.

The better ones are pay for products, or leave a reminder screen on your batchfile until you pay for it.


0

Sponsored Link
Ads by Google
Reply to Message Icon

Related Posts

See More







Post Locked

This post is quite old and has been locked from receiving new replies. Please create a new posting instead.


Go to Programming Forum Home


Sponsored links

Ads by Google


Results for: Disable editing a batch file

Editing .ini file with a batch file www.computing.net/answers/programming/editing-ini-file-with-a-batch-file/12127.html

Editing a Text File With a Batch www.computing.net/answers/programming/editing-a-text-file-with-a-batch/14889.html

Editing a Hex file using a Batch script www.computing.net/answers/programming/editing-a-hex-file-using-a-batch-script/19381.html