sleyer 2 Report post Posted May 31, 2012 halo, aku ade server dan ade lebih 12 folder yg berbeza so aku nak delete file2 sampah, mcm .mp3, .tmp [CODE] cls rem THIS WILL DELETE ALL: rem [.FAS] rem UPDATED ON 03-DECEMBER-2010 del A:\*.fas /s/f del B:\*.fas /s/f del G:\*.fas /s/f del H:\*.fas /s/f del I:\*.fas /s/f del J:\*.fas /s/f del K:\*.fas /s/f del L:\*.fas /s/f del M:\*.fas /s/f del N:\*.fas /s/f del O:\*.fas /s/f del P:\*.fas /s/f del Q:\*.fas /s/f del R:\*.fas /s/f del V:\*.fas /s/f del W:\*.fas /s/f del X:\*.fas /s/f [/CODE] coding ni ok jer.. persoalan aku adelah mcm mane aku nak buat tuk delete file2 mcm balala.pic sasa.mp3 dalam c:\ pc user ? dalam masa sama exlude folder program file Quote Share this post Link to post Share on other sites
akubudakbaik 0 Report post Posted June 4, 2012 del /s /q c:\user\*.pic *.mp3 *.apaapaje Quote Share this post Link to post Share on other sites
sleyer 2 Report post Posted June 4, 2012 [quote name='akubudakbaik' timestamp='1338793172' post='1082542'] del /s /q c:\user\*.pic *.mp3 *.apaapaje [/quote] aku just nak exlude folder program file jer... lain2 include Quote Share this post Link to post Share on other sites
mohdfadly 24 Report post Posted June 9, 2012 [CODE]del /s /q c:\user\*.pic *.mp3 *.apaapaje[/CODE] buang /s. /s bersamaan sub-folder. tambah /a. /a bersamaan all files. [CODE]del /a /q c:\user\*.pic *.mp3 *.apaapaje[/CODE] Quote Share this post Link to post Share on other sites
sleyer 2 Report post Posted June 19, 2012 [quote name='Null' timestamp='1339246677' post='1082685'] [CODE]del /s /q c:\user\*.pic *.mp3 *.apaapaje[/CODE] buang /s. /s bersamaan sub-folder. tambah /a. /a bersamaan all files. [CODE]del /a /q c:\user\*.pic *.mp3 *.apaapaje[/CODE] [/quote] batch ni akan delete file dalam c: folder user kan ? cam ne nak exlude program file ? Quote Share this post Link to post Share on other sites
mohdfadly 24 Report post Posted June 22, 2012 [CODE]@echo off cd "C:\WINDOWS" del /s /q *.mp3 cd .. cd "C:\Documents and Settings" del /s /q *.mp3[/CODE] ko boleh buat [b]for loop[/b] untuk exclude folder, tapi x pasti boleh ke tak sebab [b]del /s[/b] tu pun dah looping.. kalau boleh pun mungkin nk kena perah otak sikit.. tapi cara coding atas tu pun dah ok.. copy paste kat notepad dan save as clean.bat Quote Share this post Link to post Share on other sites