コードコピーは次のとおりです。
<%
「///////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////
'//
'//1.c:/windows/system32/cmd.exe
'//このファイルが配置されているパスをコピーします
'//
'//2.Change C:/Program/Winrar/rar.exe
'//このファイルが配置されているパスをコピーして、winrar.exeに名前を変更します
'//
「///////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////
'//
'// CompressPath(byvals)
'//圧縮ファイルへのパス|文字列バリアント
'//
'// DecompressPath(byvals)
'//ファイルのフォルダーを減圧します|文字列バリアント
'//
'//圧縮
'//オンライン圧縮
'//
'//減圧
'//オンライン減圧
'//
'// PowerBynever-online
'//
'//email:bluedestiny
'//
「///////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////
optionexplicit
classCompress_decompress_files
プライベートバージョン、著作権
privateowshshell、ofso
privatesCompressPath、sdecompressPath
privatesubclass_initialize
version = "Compress_decompress_filesbuilder20051015"
Copyright = "PowerByMiracle(Bluedestiny)"
setofso = server.createObject( "scripting.filesystemObject")
setowshshell = server.createObject( "wscript.shell")
Writeln(バージョン+"<br>"+著作権)
Endingub
privatesubclass_terminate
ifosobject(owshshell)thensetowshshell =何もない
ifosobject(ofso)thensetofso =何もない
Endingub
privateFunctionPhysicalPath(byvals)
PhysicalPath = server.mappath(s)
エンド機能
privatesubvalidatefile(byvals)
ifofso.fileexists(s)thenexitsub
ifofso.folderexists(s)thenexitsub
callerr "file(folder)notexists!"
Endingub
privatesubcreatefolder(byvals)
ifofso.folderexists(s)thenexitsub
ofso.createfolder(s)
Endingub
privatesubwriteln(byvals)
Response.Write "<p>"+s+"</p>"+vbcrlf
Endingub
privatesubcallerr(byvals)
writeln "<p> <b>エラー:</b> </p>"+s
Response.End
Endingub
privatesubcallsucc(byvals)
writeln "<p> <b>成功:</b> </p>"+s
Endingub
publicsubcompress
validateFile(ScompressPath)
owshshell.run( "winrara"+scompresspath+""+sdecompresspath& "")