![]() |
|
![]() |
|
|
Thread Tools | Display Modes |
|
|
#1 |
|
Programmer
Join Date: Jul 2006
Location: using Earth.Africa.Egypt.Cairo;
Posts: 76
Rep Power: 3
![]() |
Batch Programming
hey guys,
I've always wandered about the use of batch programming,i know that they are Dos Commands in a text file saved as a .bat file,but what is the use of such files,and does any one use those now days??? |
|
|
|
|
|
#2 | |
|
Hobbyist Programmer
Join Date: Oct 2005
Posts: 211
Rep Power: 4
![]() |
Quote:
There's reasons for it, but generally for more complex stuff I try to use perl or something similar. Here's a list of some things I've made batch files for in the past: * I had to copy files from my computer to a test server rather regularly, but not all of them, only certain types, I created a batch file to copy these for me. * I often use remote/logical drives for different projects just to keep things easier, I'll often use batch files to set up the drives the way I want for a certain project (as I switch projects a bit) * I had one project where a file on a remote device needed to stay 'release' but often needed to be switched to 'debug' for debugging, I created a script to re-name the files appropriately when debugging with one click, and back again. Hope this helps... -MBirchmeier |
|
|
|
|
|
|
#3 |
|
Programmer
Join Date: Jul 2006
Location: using Earth.Africa.Egypt.Cairo;
Posts: 76
Rep Power: 3
![]() |
ya that helped MBirchmeier thnx
![]() |
|
|
|
|
|
#4 |
|
Hobbyist Programmer
|
I use them almost daily, I primarily use them to launch my games in high priority without having to use the Task Manager. Or you can use them to delete certain files, batch rename, etc., the list goes on and on. Although it is very limiting.
I think every 'programmer' should have knowledge of how to use them, its so easy to create/use and quite useful/time saving.
__________________
Pain is just weakness leaving the body.
|
|
|
|
|
|
#5 |
|
Programmer
Join Date: Jul 2006
Location: using Earth.Africa.Egypt.Cairo;
Posts: 76
Rep Power: 3
![]() |
thnx AntiNinja,
i think i'll start learnig it. |
|
|
|
|
|
#6 |
|
SEXY SHOELESS GOD OF WAR!
![]() Join Date: Jun 2005
Location: Wet west coast of Canada
Posts: 1,198
Rep Power: 5
![]() |
One thing I use them for regularly is copying directory trees at school. Many instructors put material on the college server, and it's a pain in the ass to point-and-click navigate to the right folder, and copy it over in the GUI. It's much easier to have a batch file on my USB drive, and double-click it.
Another thing it's useful for, particularly if you have a mobile computer that connects to different networks based on location, is mapping network drives. It's much easier to double-click the batch file/shortcut thereto than it is to type some lengthy NET USE command, or navigate the many clicks and keystrokes needed to map the drive in Explorer (I am assuming the share requires a password). Yes, sometimes you can set it up to automagically connect, but occassionally, this isn't appropriate (such as when you don't want to always be connected). Lastly, they're useful for utilities that use a command-line interface. You can write a batch file to repetitively call the utility for each instance of the task (say, each file you want to process), without having to tediously type everything out.
__________________
And once again, Probability proves itself willing to sneak into a back alley and service Drama as would a copper-piece harlot. - Vaarsuvius, Order of the Stick |
|
|
|
|
|
#7 |
|
Programmer
Join Date: Feb 2006
Location: Ohio
Posts: 93
Rep Power: 3
![]() |
I use them every day. Mine are primarily for programming environment initialization, because I do most everything from the command line. I have scripts that set all my environment variables; others that have all my compile/build functionality. Then there are the quick-launch scripts that I execute via the "Run" dialog, so that I don't have to move from the keyboard to the mouse to start certain programs.
__________________
Neeley.org |
|
|
|
|
|
#8 |
|
Programmer
Join Date: Jul 2006
Location: using Earth.Africa.Egypt.Cairo;
Posts: 76
Rep Power: 3
![]() |
thnx guys that was lots of usefull info.
|
|
|
|
|
|
#9 |
|
Programmer
|
You can learn more advance batch programming from the following URL address http://www.osix.net/modules/article/?id=755
__________________
Iftikhar Ahmed Khan For doing an experiment on programmer's mood please visit http://uxisfyp1.brunel.ac.uk/cspgiak |
|
|
|
![]() |
| Bookmarks |
| Currently Active Users Viewing This Thread: 1 (0 members and 1 guests) | |
| Thread Tools | |
| Display Modes | |
|
|
Similar Threads
|
||||
| Thread | Thread Starter | Forum | Replies | Last Post |
| Programming without post secondary education | Eric the Red | Other Programming Languages | 6 | Mar 7th, 2006 6:56 PM |
| Does Programming Make You Smarter? | Sane | Coder's Corner Lounge | 43 | Oct 2nd, 2005 7:12 AM |
| MIT's Metaphor For Software Programming | Infinite Recursion | Other Programming Languages | 2 | Jun 12th, 2005 7:42 AM |