ªð¦^¦Cªí ¤W¤@¥DÃD µo©«

[µo°Ý] ¦p¦ó§Ö³t«Ø¥ßªÅ¥Õ¸ê®Æ§¨

¥»©«³Ì«á¥Ñ GBKEE ©ó 2012-4-5 13:42 ½s¿è

¦^´_ 1# luke
  1. Option Explicit
  2. Sub «Ø¥ß()
  3.     Dim Rng As Range, xF As Variant, xlDesktop As String
  4.     Set Rng = Range("A7:A" & [A7].End(xlDown).Row)
  5.     Set xF = Rng.Find([b1], lookat:=xlWhole)
  6.      If xF Is Nothing Then Exit Sub
  7.     xF = Application.Transpose(Application.Transpose(Cells(xF.Row, "a").Resize(, 3).Value))
  8.     xF = Join(xF, "-") & "-" & Format(Date, "yymmdd")
  9.     xlDesktop = Get_Desktop
  10.     If Dir(xlDesktop & xF, 16) = "" Then MkDir (xlDesktop & xF)  '
  11. End Sub
  12. Sub ¥þ¿ï()
  13.     Dim E As Range, xF As Variant, xlDesktop As String
  14.      xlDesktop = Get_Desktop
  15.      For Each E In Range("A7:A" & [A7].End(xlDown).Row)
  16.         xF = Application.Transpose(Application.Transpose(Cells(E.Row, "a").Resize(, 3).Value))
  17.         xF = Join(xF, "-") & "-" & Format(Date, "yymmdd")
  18.         If Dir(xlDesktop & xF, 16) = "" Then MkDir (xlDesktop & xF)
  19.     Next
  20. End Sub
  21. Private Function Get_Desktop() As String  '¨ç¼Æ : ¶Ç¦^©Ò¦b¹q¸£ªº®à­±¸ô®|
  22.     Dim ob As Object
  23.     Set ob = CreateObject("Wscript.Shell")
  24.     Get_Desktop = ob.SpecialFolders("Desktop") & "\"
  25. End Function
½Æ»s¥N½X

TOP

        ÀR«ä¦Û¦b : ½_ÁJµ²±o¶V¹¡º¡¡A¶V·|©¹¤U««¡A¤@­Ó¤H¶V¦³¦¨´N¡A´N­n¶V¦³Á¾¨Rªº¯ÝÃÌ¡C
ªð¦^¦Cªí ¤W¤@¥DÃD