How to Use Batch Files to Complete Routine Tasks

Batch files may well date back to the early 1980s but there are still some uses left for them that will make administering your Windows network easier. It’s hard to imagine in today’s day and age that we’d still be going back to batch files but there are some uses that can be made that little bit easier by using them and in this article we’ll explore just a few things they can do to make your life a little simpler as an IT administrator.

Firstly it’s important to understand what a batch file is. Put basically it’s simply a text file that is saved with the extension .bat. In the days of DOS you’d need to use an old 16bit application called ‘edit’ to edit but in Windows you can just use Notepad or any other plain text editor. It’s good to remember that if you have file extensions hidden that your newly created batch file might be created with txt extension. Needless to say, your batch files will not run properly with this extension so turning on extensions for known file types is essential if you haven’t already done so.

Inside a typical batch file you’ll find a list of DOS commands, one per line which execute in that exact order. A typical use for a batch file in the DOS days was to create menu systems and automated tasks that are laborious by anyone’s standards.

One of the best uses for batch files in modern times is to run backup tasks which would otherwise need to be done by manually inputting the commands, effectively creating a short script of command can save you lots of time. As well as being able to use the usual commands such as CD, MD and COPY in a batch file, Windows 7 offers a more advanced copy solution called Robocopy. One really useful advantage of this more advanced copy command is the ability to copy files between network shares. This was an impossible task using a UNC path in the old version of the COPY command. Something to remember when using batch files is that UNC paths are not usually recognised. The simple and effective way to get around this minor annoyance is to map drives to the UNC paths to effectively give your batch files the ability to connect and use network paths. The simple way to do this is by right clicking on a network share and choosing the map network drive option and selecting a drive letter to connect to. Alternatively if you want to perform this task at the command prompt then the same task can be managed via the net use command.

Many businesses these days are choosing to outsource their IT support in order to tap into knowledge like that shown in this article. A big benefit of outsourcing it support London is to gain the resources of many engineers who have been working in IT for a long time and have the skill sets required to complete administrative and maintenance tasks with the use of clever tools such as little batch files.

A simple and often quite useful command which can be embedded into a batch file is the opening of windows applications in either minimized or maximized states. Another switch often used by network administrators is the wait switch. This is useful if you want to close an application and wait whilst it completes a routine backup of the data files or completes a procedure to delete files when exiting an application. You can also specify which application will open a particular file type by calling the file and specifying the exact application to open the file. This is a good workaround opening a file by its default program by file association.

Outsource IT Support London | Personalised Gifts

An IT Support specialist in Outsource IT Support in London, Essex & Kent. http://www.newvisionnetworks.net

Author Bio: Outsource IT Support London | Personalised Gifts

Category: Computers and Technology
Keywords: it support london,computer support london,network support london,outsource it support london

Leave a Reply