loading
Picture of How to make Batch files Install any file!
Ever want to give a download on an instructable, but it has to be in the correct folder? Here's how you can make a simple installer that can create multiple files, given you created it correctly. You will need

-a Windows NT (or higher) computer
-patience
-a file you want to install
-a place to put the file

Step 1: The most basic of text editing

Picture of The most basic of text editing
Before we start programming we are going to have to open notepad.

Windows 95-2000
Start>Programs>Acessories>Notepad

Windows XP-7

Start>All Programs>Acessories>Notepad

Then proceed to the next step.
 
TwinDaddyD2 months ago
I'm fairly new to batch files, so I'm hoping you can help me. I am running updates and a few installs on roughly 450 computers. Because our network is older, we have to do most of the installs and updates ourselves. Is it possible, and would it save time, to create a batch file that copies half a dozen files from the server to the desktop and installs them automatically, even if the installs have multiple 'clicks?' I have to log into our districts' filter first. I also run Windows Updates, clean out old system files, run ScanDisk and Disk Defrag, and create a restore point.

Any ides?

Thanks!
Super_Nerd (author)  TwinDaddyD2 months ago

Most of that would be possible as it's copying and running files, however, I'm not to sure how well networked storage works with batch files. It's certainly worth a try though. Difficulty may arise in file paths if the files to be copied have different names/paths every update, but other than that, I'd imagine such a file could be created.

I had some success copying the folder from the network drive to my desktop, although it made it a folder within a folder on my desktop...

How would you go about writing instructions to install a program where you have to "opt out" of add-ons like toolbars, etc.? For example, when installing Java, you have to run the .exe, Tell UAC to allow the install, then click "Install" within in installation program. After a couple of minutes, an option to set everything to Yahoo comes up. After declining that, it will install Java. There are usually three more "Nexts" to click before the install is complete and all old versions are removed.

Super_Nerd (author)  TwinDaddyD2 months ago

Most of what you're asking isn't possible through ordinary batch files. As they can only run DOS commands, they can't do everything. You would probably want to make a VBS script to go though the installation (although I have pretty much no experience with using VBS with other programs, I do believe there are some interaction features.) As for UAC, there isn't a non-manual way around it as it's designed to not be automated to help protect your system from viruses and other malware. The only way to not have to deal with it is to disable it, which can be done through the control panel. Phew, hope that helps.

Thanks. I kind of figured there wasn't going to be an easy way out of doing all those computers manually. I appreciate the advice though!

Super_Nerd (author)  TwinDaddyD2 months ago

No problem! Glad to be of at least some assistance. Good luck.

TamanbirS8 months ago

hey i want to install a specific file whenever my usb is inserted on a pc. ? is there any way to do. kindly revert back asap..

Super_Nerd (author)  TamanbirS8 months ago

I believe there is a way with a specific type of USB drive. I forget which brand, but there's one that interacts with the computer like a CD. Then you need to make an autorun file. I haven't ever done anything like that before, but I can remember seeing something like that before.

I have a sandisk pendrive and a windows 8.1. I have added a keylogger in my pendrive which can run on clicking on it but i want that the keylogger should automatically run on its own whenever pendrive is inserted and the second problem is the autorun file doesn't work for windows 8.1 because windows open the folder itself. Usually everyone have windows 8 so autorun isn't the solution to this thats why i wanted to run the keylogger itself whenever the usb is inserted. Kindly solve
Super_Nerd (author)  TamanbirS8 months ago

I'm sorry, but I don't know of any way to do that. That doesn't mean it's impossible, I just don't have much experience with Windows 8 to be able to help you. Good luck with your project though.

TamanbirS8 months ago

hey i want to install a specific file whenever my usb is inserted on a pc. ? is there any way to do. kindly revert back asap..

OwenH110 months ago

You can also download something I made. You can edit the code in the file and then copy and paste it into a batch file. Only 100 lines of code, enjoy:

https://www.mediafire.com/?nolf7eg1kmzeflb

If you have any problems you can email me at theredstoneman1001@gmail.com

Thanks, and I hope it works for you guys.

jakejakey1208 made it!1 year ago

I Have Created A Batch File That will let you create installer.exe files for free and very easily.
All you need is my InstallMaker.bat file and then it will say loading give it a second and then it will open the install maker.

TESTED ON WINDOWS 8 [It Works]

NOT SURE FOR OTHER OPERATING SYSTEMS

This is 100% free and only 1 file must be downloaded.

DOWNLOAD: http://www.mediafire.com/download/hlkw8r1v4o4vt4f/InstallMaker.bat

bandicam 2014-06-11 21-21-28-395.jpg
Why did you put VBs in the starting image?

(Someone could get confused).
Super_Nerd (author)  Prof. Pickle2 years ago
Actually that is the WinXP image for a batch file. The image for a VBS file looks like this
VBS.png
Sorry, I meant the image at step 1

Sorry for the confusions
Super_Nerd (author)  Prof. Pickle2 years ago
Well the picture is more for the image of notepad than the code in it.
Fair enough.
Chad Baxter2 years ago
Why don't you join the Batch Homies Group and post your Batch Instructables?
http://www.instructables.com/group/BatchHomies/
Not really an installer... As far as I can see, it's writing strings to a file. Pree basic stuff, but good instructable :)
Super_Nerd (author)  threeflashes3 years ago
Well, it can be used to behave like an installer. Oh well, thanks for reading!