Overclock.net › Forums › Software, Programming and Coding › Coding and Programming › Write me a simpe batch (.bat) files
New Posts  All Forums:Forum Nav:

Write me a simpe batch (.bat) files - Page 2

post #11 of 18
Make a new .txt file, put this to it:

Code:
cd\\
cd C:/Program files/ProgramFolder/
del program.exe
save as .bat, and run it.
Gaming Rig
(13 items)
 
  
CPUMotherboardGraphicsRAM
AMD Athlon 64 x2 4600+ AM2 Dell 0CT103 EVGA GeForce 9600GT 512MB 4 x 1GB Wintec (DDR2-667) 
Hard DriveOSMonitorCase
SAMSUNG HD160JJ/P SATA-II 160GB Windows Vista Ultimate x64 Dell 1907FP 19" Dell Dimension E521 
Mouse
Logitech MX518 
  hide details  
Reply
Gaming Rig
(13 items)
 
  
CPUMotherboardGraphicsRAM
AMD Athlon 64 x2 4600+ AM2 Dell 0CT103 EVGA GeForce 9600GT 512MB 4 x 1GB Wintec (DDR2-667) 
Hard DriveOSMonitorCase
SAMSUNG HD160JJ/P SATA-II 160GB Windows Vista Ultimate x64 Dell 1907FP 19" Dell Dimension E521 
Mouse
Logitech MX518 
  hide details  
Reply
post #12 of 18
alternatively you can use erase instead of del
SUPERPWN
(12 items)
 
  
CPUMotherboardGraphicsRAM
Core i5 4670K Asus z87-Pro MSI GTX 1080 Aero 32GB DDR3 Gskill Ripjaws 
Hard DriveOSMonitorMonitor
4TB Seagate Windows 8 x64 Overlord x270 OC HP ZR27 
MonitorKeyboardPowerAudio
Asus PG279Q G-Tune Topre Realforce 800w Yulong D100 DAC with Denon D7000 headphones 
  hide details  
Reply
SUPERPWN
(12 items)
 
  
CPUMotherboardGraphicsRAM
Core i5 4670K Asus z87-Pro MSI GTX 1080 Aero 32GB DDR3 Gskill Ripjaws 
Hard DriveOSMonitorMonitor
4TB Seagate Windows 8 x64 Overlord x270 OC HP ZR27 
MonitorKeyboardPowerAudio
Asus PG279Q G-Tune Topre Realforce 800w Yulong D100 DAC with Denon D7000 headphones 
  hide details  
Reply
post #13 of 18
Quote:
Originally Posted by Dennisjr13 View Post
Make a new .txt file, put this to it:

Code:
cd\\
cd C:/Program files/ProgramFolder/
del program.exe
save as .bat, and run it.
Also, if you do that, it deletes the file without sending it to the recycle bin. So be careful.


Edit: I don't think that code will work, try this if it doesnt:

Code:
cd ..\\..\\..\\..
cd C:\\Program Files\\ProgramFolder
del Program.exe
über pwnage v2
(15 items)
 
  
CPUMotherboardGraphicsRAM
i7 2600K 4.4GHz @ 1.36v Asus P8Z68-V LX EVGA GTX 970 SuperClocked ACX2.0 4GB G.SKILL Ripjaws X 2x8GB DDR3 @ 1648MHz 
Hard DriveOptical DriveCoolingOS
840EVO 250GB / 3TB+2TB+320GB Bar / 750GB Cav Blk Samsung DVDRW Hyper 212+ Windows 10 Pro x64 
MonitorKeyboardPowerCase
U2412M + X191W Azio MGK1 Corsair RM650X Centurion 5 with acoustic foam 
MouseMouse PadAudio
MX518 SteelSeries Xonar DG + Koss PortaPro + Logitech X-540 + Bey... 
  hide details  
Reply
über pwnage v2
(15 items)
 
  
CPUMotherboardGraphicsRAM
i7 2600K 4.4GHz @ 1.36v Asus P8Z68-V LX EVGA GTX 970 SuperClocked ACX2.0 4GB G.SKILL Ripjaws X 2x8GB DDR3 @ 1648MHz 
Hard DriveOptical DriveCoolingOS
840EVO 250GB / 3TB+2TB+320GB Bar / 750GB Cav Blk Samsung DVDRW Hyper 212+ Windows 10 Pro x64 
MonitorKeyboardPowerCase
U2412M + X191W Azio MGK1 Corsair RM650X Centurion 5 with acoustic foam 
MouseMouse PadAudio
MX518 SteelSeries Xonar DG + Koss PortaPro + Logitech X-540 + Bey... 
  hide details  
Reply
post #14 of 18
I tested it using a different directory and file, it works but it will delete the file permanently so be careful .
Gaming Rig
(13 items)
 
  
CPUMotherboardGraphicsRAM
AMD Athlon 64 x2 4600+ AM2 Dell 0CT103 EVGA GeForce 9600GT 512MB 4 x 1GB Wintec (DDR2-667) 
Hard DriveOSMonitorCase
SAMSUNG HD160JJ/P SATA-II 160GB Windows Vista Ultimate x64 Dell 1907FP 19" Dell Dimension E521 
Mouse
Logitech MX518 
  hide details  
Reply
Gaming Rig
(13 items)
 
  
CPUMotherboardGraphicsRAM
AMD Athlon 64 x2 4600+ AM2 Dell 0CT103 EVGA GeForce 9600GT 512MB 4 x 1GB Wintec (DDR2-667) 
Hard DriveOSMonitorCase
SAMSUNG HD160JJ/P SATA-II 160GB Windows Vista Ultimate x64 Dell 1907FP 19" Dell Dimension E521 
Mouse
Logitech MX518 
  hide details  
Reply
post #15 of 18
Thread Starter 
Quote:
Originally Posted by Dennisjr13 View Post
I tested it using a different directory and file, it works but it will delete the file permanently so be careful .
That's the goal
Rig 2.1
(16 items)
 
  
CPUMotherboardGraphicsRAM
Intel i7 3770k ASUS P8Z77-V LK Sapphire 7850 1GB G.SKILL Ripjaws X 8GB (2 x 4GB) DDR3 F3-12800CL... 
Hard DriveHard DriveOptical DriveCooling
Western Digital Blue 1TB WD10EZEX Search Results Crucial MX100 CT256MX100SSD1 256GB ASUS DRW-24B1ST DVD±R/RW Zalman CNPS10X Optima 
OSMonitorKeyboardPower
Windows 7 Ultimate 64-bit Dell 23" IPS CM Storm Quick Fire Pro Brown OCZ StealthXStream 600W 
CaseMouseAudio
Antec P182 Logitech MX518 Logitech X-530 
  hide details  
Reply
Rig 2.1
(16 items)
 
  
CPUMotherboardGraphicsRAM
Intel i7 3770k ASUS P8Z77-V LK Sapphire 7850 1GB G.SKILL Ripjaws X 8GB (2 x 4GB) DDR3 F3-12800CL... 
Hard DriveHard DriveOptical DriveCooling
Western Digital Blue 1TB WD10EZEX Search Results Crucial MX100 CT256MX100SSD1 256GB ASUS DRW-24B1ST DVD±R/RW Zalman CNPS10X Optima 
OSMonitorKeyboardPower
Windows 7 Ultimate 64-bit Dell 23" IPS CM Storm Quick Fire Pro Brown OCZ StealthXStream 600W 
CaseMouseAudio
Antec P182 Logitech MX518 Logitech X-530 
  hide details  
Reply
post #16 of 18
The one line one that pauldovi posted is the best, as it is the smallest.

Using the Cd\\ is not necessary with the delete command if you specify the full path.

The best way to use boris4ka's method would be to do this:

c:
cd\\Program Files\\ProgramFolder
del program.exe
SUPERPWN
(12 items)
 
  
CPUMotherboardGraphicsRAM
Core i5 4670K Asus z87-Pro MSI GTX 1080 Aero 32GB DDR3 Gskill Ripjaws 
Hard DriveOSMonitorMonitor
4TB Seagate Windows 8 x64 Overlord x270 OC HP ZR27 
MonitorKeyboardPowerAudio
Asus PG279Q G-Tune Topre Realforce 800w Yulong D100 DAC with Denon D7000 headphones 
  hide details  
Reply
SUPERPWN
(12 items)
 
  
CPUMotherboardGraphicsRAM
Core i5 4670K Asus z87-Pro MSI GTX 1080 Aero 32GB DDR3 Gskill Ripjaws 
Hard DriveOSMonitorMonitor
4TB Seagate Windows 8 x64 Overlord x270 OC HP ZR27 
MonitorKeyboardPowerAudio
Asus PG279Q G-Tune Topre Realforce 800w Yulong D100 DAC with Denon D7000 headphones 
  hide details  
Reply
post #17 of 18
Thread Starter 
Quote:
Originally Posted by Crazy9000 View Post
The one line one that pauldovi posted is the best, as it is the smallest.

Using the Cd\\ is not necessary with the delete command if you specify the full path.

The best way to use boris4ka's method would be to do this:

c:
cd\\Program Files\\ProgramFolder
del program.exe
Well, I tested it, and it works, so therefore, I'm happy
Rig 2.1
(16 items)
 
  
CPUMotherboardGraphicsRAM
Intel i7 3770k ASUS P8Z77-V LK Sapphire 7850 1GB G.SKILL Ripjaws X 8GB (2 x 4GB) DDR3 F3-12800CL... 
Hard DriveHard DriveOptical DriveCooling
Western Digital Blue 1TB WD10EZEX Search Results Crucial MX100 CT256MX100SSD1 256GB ASUS DRW-24B1ST DVD±R/RW Zalman CNPS10X Optima 
OSMonitorKeyboardPower
Windows 7 Ultimate 64-bit Dell 23" IPS CM Storm Quick Fire Pro Brown OCZ StealthXStream 600W 
CaseMouseAudio
Antec P182 Logitech MX518 Logitech X-530 
  hide details  
Reply
Rig 2.1
(16 items)
 
  
CPUMotherboardGraphicsRAM
Intel i7 3770k ASUS P8Z77-V LK Sapphire 7850 1GB G.SKILL Ripjaws X 8GB (2 x 4GB) DDR3 F3-12800CL... 
Hard DriveHard DriveOptical DriveCooling
Western Digital Blue 1TB WD10EZEX Search Results Crucial MX100 CT256MX100SSD1 256GB ASUS DRW-24B1ST DVD±R/RW Zalman CNPS10X Optima 
OSMonitorKeyboardPower
Windows 7 Ultimate 64-bit Dell 23" IPS CM Storm Quick Fire Pro Brown OCZ StealthXStream 600W 
CaseMouseAudio
Antec P182 Logitech MX518 Logitech X-530 
  hide details  
Reply
post #18 of 18
Quote:
Originally Posted by bentrinh View Post
Well, I tested it, and it works, so therefore, I'm happy
For casual use anything that does it should work. However if you end up making larger batch files in the future, it is best to learn to make them as concise as possible so that they are easier to troubleshoot. Good habit to have.
SUPERPWN
(12 items)
 
  
CPUMotherboardGraphicsRAM
Core i5 4670K Asus z87-Pro MSI GTX 1080 Aero 32GB DDR3 Gskill Ripjaws 
Hard DriveOSMonitorMonitor
4TB Seagate Windows 8 x64 Overlord x270 OC HP ZR27 
MonitorKeyboardPowerAudio
Asus PG279Q G-Tune Topre Realforce 800w Yulong D100 DAC with Denon D7000 headphones 
  hide details  
Reply
SUPERPWN
(12 items)
 
  
CPUMotherboardGraphicsRAM
Core i5 4670K Asus z87-Pro MSI GTX 1080 Aero 32GB DDR3 Gskill Ripjaws 
Hard DriveOSMonitorMonitor
4TB Seagate Windows 8 x64 Overlord x270 OC HP ZR27 
MonitorKeyboardPowerAudio
Asus PG279Q G-Tune Topre Realforce 800w Yulong D100 DAC with Denon D7000 headphones 
  hide details  
Reply
New Posts  All Forums:Forum Nav:
  Return Home
  Back to Forum: Coding and Programming
Overclock.net › Forums › Software, Programming and Coding › Coding and Programming › Write me a simpe batch (.bat) files