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

[µo°Ý] getFolder¦p¦ó¨ú±o¨ì²Ä¤G¼h¸ê®Æ§¨

[µo°Ý] getFolder¦p¦ó¨ú±o¨ì²Ä¤G¼h¸ê®Æ§¨

§Ú·Q½Ð°Ý°ª¤â­Ì¡A¥Ø«e¥H¤Uµ{¦¡½X¥u¯à°µ¨ìŪ¨ú¤@¼h¸ê®Æ§¨ªºÅª¨ú¦Ó¤w¡A½Ð°Ý­þ¸Ì¼g¿ù¤F¹À
§Ú·Q­n¥i¥HŪ¨ú§Ú¿ï¾Ü¦nªº¥Ø¿ý¤U©Ò¦³ªº¸ê®Æ§¨¡A¥i¬O¤£ª¾¹D­þ¸Ì¼g¿ù¤F
¤w¸gª¦¤å³\¤[¡A¦ý©l²×µLªk§ä¨ìµª®×¡A½Ð°ª¤â­Ì«üÂI°g¬z¡A·P®¦
  1. Set oexcel = CreateObject("Excel.Application")
  2.     Dim objF As Object  '©w¸q¶}Àɪ«¥ó
  3.     Dim strFoldersName As String    '©w¸q¸ê®Æ§¨¦WºÙ¬°¦r¦ê«¬ºA
  4.     Dim strAllName As String   '©w¸q©Ò¦³¦WºÙ
  5.     'Dim objFs2 As Scripting.FileSystemObject
  6.    
  7.     Dim fObj2, fc2
  8.     Dim objF2 As Object
  9.    
  10.    
  11.     Dim strFolderPath As String
  12.     Dim strGetFilePath As String
  13.     strGetFilePath = File1.Path
  14.    
  15.     strFolder = Text1.Text
  16.    
  17.     Set gobjFs = CreateObject("Scripting.FileSystemObject")
  18.     Set objF = gobjFs.GetFolder(strGetFilePath)
  19.     Set fc = objF.SubFolders
  20.    
  21.     For Each F1 In fc
  22.         
  23.      
  24. 'Set oexcel = CreateObject("Excel.Application")

  25. MyPath = F1


  26. i = 0


  27. MyFile = Dir(MyPath & "\*_1.csv")  '­n¶}±Òªº¸ê®ÆÀɦW


  28.                            
  29. 'g = Mid(MyFile, 1, 18)

  30.     Do While Len(MyFile) > 0
  31.    
  32.    
  33.    
  34.     Call class_NT
  35.     Application.DisplayAlerts = False  ' Ãö³¬Äµ§i°T®§
  36.    
  37.     Application.DisplayAlerts = True   ' ¦A¥´¶}ĵ§i°T®§
  38.     i = i + 1
  39.     MyFile = Dir                                                     '¤U¤@µ§
  40.     Loop
  41.     Next
½Æ»s¥N½X

¦^´_ 1# z15935712

·j´M¤@¤U ¸ê®Æ§¨
·P®¦ªº¤ß......(¦b³Â»¶®a±Ú°Q½×°Ï.¥Î¤ß¾Ç²ß·|¦³¶i¨Bªº)
¦ý¸ê·½µL­­,«á´©¦³­­,  ¤@¤Ñ1¤¸ªºÃÙ§U,¤H¤H¦³¯à¤O.

TOP

­è­èª¦§¹GEKEE ¤j¤jªº¤å³¹
½Ð°Ý·j´M¥Ø¼Ð¸ê®Æ§¨¤¤©³¤Uªº©Ò¦³¤l¸ê®Æ§¨¬O­þ¤@¬q?
¯àÀ°§Ú¥[¤Wµù¸Ñ¶Ü¡AÁÂÁÂ

TOP

½Ð°Ý·j´M¥Ø¼Ð¸ê®Æ§¨¤¤©³¤Uªº©Ò¦³¤l¸ê®Æ§¨¬O­þ¤@¬q?
coblo µoªí©ó 2014/9/4 17:46




¦p¹Ï ³v¨B°õ¦æ,¨ìVBAµøµ¡«ö F8 ¥iºCºCêí¸Ñ.
·P®¦ªº¤ß......(¦b³Â»¶®a±Ú°Q½×°Ï.¥Î¤ß¾Ç²ß·|¦³¶i¨Bªº)
¦ý¸ê·½µL­­,«á´©¦³­­,  ¤@¤Ñ1¤¸ªºÃÙ§U,¤H¤H¦³¯à¤O.

TOP

        ÀR«ä¦Û¦b : ¤â¤ß¦V¤U¬O§U¤H¡A¤â¤ß¦V¤W¬O¨D¤H¡F§U¤H§Ö¼Ö¡A¨D¤Hµh­W¡C
ªð¦^¦Cªí ¤W¤@¥DÃD