精華區beta EZsoft 關於我們 聯絡資訊
※ 引述《HZYSoft (PCMan 2004)》之銘言: : 用 script 就可以做的事情,不用出動 120 kb 的大軟體 : 請將以下程式碼貼上到記事本,存檔,類型選「所有檔案」,命名為 file_list.vbs : --------------------------檔案開始--------------------------- 呵 看到這篇文章讓我不禁也想來惡搞一下, 讓我們來看看 MS-DOS 能做到甚麼程度。 :P 這也是個既熟悉又陌生的好伙伴呢!嘿! ──────────────────────────────── 直接雙擊的話會將.bat檔所屬的目錄底下做成$file.htm 拖曳資料夾的話會出現該資料夾底下的資料 只列出檔案,不列出資料夾,也就是如果資料夾底下沒檔案就不列了。:P 檔案 http://tony1223.no-ip.info/PTT/filelist.bat 結構 http://tony1223.no-ip.info/PTT/$files.htm (filelist.bat 我加入了一行 rem掉的header,好讓程式會執行下載) rem <meta http-equiv="Content-Type" content="application; charset=big5"> ----source-------------------- set dir=. if not "%1" =="" ( set dir=%1 set Address=%1\$files.htm ) else (for %%f in ($files.htm) do set Address=%%~ff) date/t > "%Address%" echo ^<br /^> >> "%Address%" for /R %dir% %%f in (*.*) do ( echo %%~pf ^<a href='%%~f'^> %%~nxf ^</a^> %%~af %%~tf ^<br ^> >> "%Address%" ) "%SYSTEMDRIVE%\Program Files\Internet Explorer\iexplore.exe" "%Address%" set Address= set dir= -- String temp="relax"; | Life just like programing while(buringlife) String.forgot(temp); | to be right or wrong while(sleeping) brain.setMemoryOut(); | need not to say stack.push(life.running); | the compiler will stack.push(scouting.buck()); | answer your life stack.push(bowling.practice()); | Bone everything -- ※ 發信站: 批踢踢實業坊(ptt.cc) ◆ From: 220.134.27.68
TonyQ:拖曳資料夾的話 > 更正為 將資料夾拖曳到批次檔上 05/05 02:41
※ 編輯: TonyQ 來自: 220.134.27.68 (05/05 02:42)
JCeel:哇! 很棒內! 05/05 06:54
JCeel:但我把source那行下的原始碼貼在Notepad後存成*.bat沒用耶?? 05/05 07:02
JCeel:但提供下載的那個可以用! Thank you! 05/05 07:04
JCeel:但資料夾底下若有"資料夾+檔案",一樣沒作用... 05/05 07:07