Scripting Runtime Library(FileSystemObject)

ÁöÁ¤µÈ Æú´õ¸¦ ¸¸µç´Ù.

Àμö/ÆĶó¸ÞÅÍ
objectName
ÇʼöÀûÀÎ ¿ä¼ÒÀ̸ç, Ç×»ó FileSystemObjectÀÇ À̸§ÀÌ´Ù.
foldername
ÇʼöÀûÀÎ ¿ä¼ÒÀ̸ç, ¸¸µé Æú´õ¸¦ ³ªÅ¸³»´Â ¹®ÀÚ½ÄÀÌ´Ù.
¼³¸í

ÁöÁ¤ÇÑ Æú´õ¸¦ ¸¸µç´Ù.

ÁöÁ¤ÇÑ Æú´õ°¡ ÀÌ¹Ì ÀÖÀ¸¸é ¿À·ù°¡ ¹ß»ýÇÑ´Ù.


CreateFolder ¸Þ¼­µå¸¦ »ç¿ëÇÏ¿© Æú´õ¸¦ ¸¸µå´Â ¿¹Á¦

°á°ú Ç¥½Ãâ
JScript CreateFolder ¸Þ¼­µå ¿¹Á¦
<SCRIPT language=JScript>
function CreateFolderTest(folderPath){
  var fso=new ActiveXObject('Scripting.FileSystemObject');
  if (fso.FolderExists(folderPath)) fso.DeleteFolder(folderPath);
  var folderObj=fso.CreateFolder(folderPath);
  str='"'+folderPath+'"°¡ »ý¼ºµÇ¾ú´Ù.';
  return(str);
}
</SCRIPT>

<DIV id=showjs class=show alt="°á°ú">°á°ú Ç¥½Ãâ</DIV>
<DIV class=show
  onClick="showjs.innerHTML=CreateFolderTest('C:\\JsTest\\CreateTest')">
  <SPAN class=ie>JScript</SPAN> <SPAN class=method>CreateFolder</SPAN> ¸Þ¼­µå ¿¹Á¦</DIV>
°á°ú Ç¥½Ãâ
VBScript CreateFolder ¸Þ¼­µå ¿¹Á¦
<SCRIPT language=VBScript>
Function CreateFolderTestvb(folderPath)
  Dim fso,folderObj
  Set fso=CreateObject("Scripting.FileSystemObject")
  If fso.FolderExists(folderPath) Then
    fso.DeleteFolder(folderPath)
  End If
  Set folderObj=fso.CreateFolder(folderPath)
  str="'"&folderPath&"'°¡ »ý¼ºµÇ¾ú´Ù."
  CreateFolderTestvb=str
End Function
</SCRIPT>

<DIV id=showvb class=show alt="°á°ú">°á°ú Ç¥½Ãâ</DIV>
<DIV class=show
  onClick="showvb.innerHTML=
    CreateFolderTestvb('C:\\JsTest\\CreateTest')">
  <SPAN class=ie>VBScript</SPAN> <SPAN class=method>CreateFolder</SPAN> ¸Þ¼­µå ¿¹Á¦</DIV>