' ・ユ・。・、・・キ・ケ・ニ・爭ェ・ヨ・ク・ァ・ッ・ネ、シ霹タ、ケ、。」 Set fso = WScript.CreateObject("Scripting.FileSystemObject") ' ニノユ、ホタクタョ yDate = year(now()) moDate = Right(00 & Month(now()), 2) daDate = Right(00 & Day(now()), 2) hoDate = Right(00 & Hour(now()), 2) miDate = Right(00 & Minute(now()), 2)
if miDate = 00 then
hoDate = Right(00 & Hour(now()), 2) -1 miDate = "59"
else
miDate = Right(00 & Minute(now()), 2) -1
end if
strDate = yDate & moDate & daDate & hoDate & miDate
' ' ・ヌ・」・・ッ・ネ・熙サリト chkDir = "C:\Documents and Settings\PT4\・ヌ・ケ・ッ・ネ・テ・ラ\test\"
' ・ィ・鬘シ・皈テ・サ。シ・ク errMsg = "・ィ・鬘シ、ャネッタク、キ、ニ、、、゙、ケ。ェ"
' ・ユ・。・、・フセ、サリト errLog = chkDir & strDate
' イサタシ・ユ・。・、・、ホサリト strSoundFile = "C:\WINDOWS\Media\Windows XP Ringin.wav"
' ・ユ・。・、・、ホツクコ゚、ウホヌァ、ケ、 If FileExists( errLog & "*" ) Then
set objectShell = CreateObject("wscript.Shell") strCommand = "sndrec32 /play /close " & chr(34) & strSoundFile & chr(34) objectShell.Run strCommand, 0, True errNow = Now() WScript.Echo errMsg,"(",errNow,")"
End If
' ・ェ・ヨ・ク・ァ・ッ・ネ、ホウォハ Set fso = Nothing
Function FileExists(Spec) Dim fso Dim ParentFolderName Set fso=CreateObject("Scripting.FileSystemObject") ParentFolderName=fso.GetParentFolderName(Spec) If ParentFolderName="" Then ParentFolderName="." On Error Resume Next fso.CopyFile Spec,ParentFolderName 'fso.MoveFile Spec,ParentFolderName FileExists=Err.Number<>53 End Function