Skip to content

Instantly share code, notes, and snippets.

View BlueSkyDetector's full-sized avatar

Takanori Suzuki BlueSkyDetector

View GitHub Profile
@BlueSkyDetector
BlueSkyDetector / files_count.js
Created January 12, 2011 03:44
このスクリプト単体で次のように実行するとC:\のファイル数が取得可能。 > cscript //Nologo files_count.js "C:\"
function getDirectoryFilesCount(path) {
var fd = new ActiveXObject("Scripting.FileSystemObject");
var d;
var ret;
try {
d = fd.GetFolder(path);
ret = d.Files.Count;
} catch(e) {