VBA ¦p¦ó±N¿ï¨úªº¸ê®Æ¡]¬YÓ¢û¢ð¢í¢í¢ü¡^, ¶K¦b·s¶}±Òªº¤£¦Psheet¤W
- ©«¤l
- 27
- ¥DÃD
- 11
- ºëµØ
- 0
- ¿n¤À
- 38
- ÂI¦W
- 0
- §@·~¨t²Î
- window
- ³nÅ骩¥»
- window7
- ¾\ŪÅv
- 10
- ©Ê§O
- ¨k
- µù¥U®É¶¡
- 2019-12-12
- ³Ì«áµn¿ý
- 2021-4-21
|
VBA ¦p¦ó±N¿ï¨úªº¸ê®Æ¡]¬YÓ¢û¢ð¢í¢í¢ü¡^, ¶K¦b·s¶}±Òªº¤£¦Psheet¤W
¢Ö¢í¢ô¢ô¢÷¡@¦U¦ì¤j¤j
¥H¤U¬O±NExcel file A ¤¤ªº©Ò¦³sheets¡@¡]¢í£A¡G¢û¢ð¢í¢í¢ü¢°¡þ¢û¢ð¢í¢í¢ü¢±¡D¡D¡D¡A³£©I¥s¨Ã¶K¤W¦b°õ¦æÀÉExcel file B¤W¡D
·Q½Ð°ÝY§Ú¥unFile B ¤¤ªº¬YÓsheet , ¤Î³oÓsheet¤¤ªº¬Y¤@¬qÈ(ex: sheet1ªº range(Bxx :Bxx)and rangf(Dxx,Dxx)'©I¥s¨Ã¶K¤W¦b°õ¦æÀÉExcel file B¤W ,½Ð°Ý¸Ó¦p¦ó§ï¼g????
·PÁ«ü±Ð- Sub DATA_INPUT()
- fds = Application.GetOpenFilename("Excel Files (*.xlsm;*.xlsx), *.xlsm;*.xlsx", , , , True)
-
- If IsArray(fds) Then
- For i = 1 To UBound(fds)
- [A2].Offset(i - 1) = fds(i)
- Next
- End If
- '''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''
- On Error Resume Next '''''' ¿ù»~¸õ¹L
- For Each a In Range([A2], Cells(Rows.Count, 1).End(xlUp))
- With Workbooks.Open(a)
- .Sheets.Copy After:=ThisWorkbook.Sheets(ThisWorkbook.Sheets.Count)
- .Close 0
- End With
- Next
- On Error GoTo 0 '''''''''''''¿ù»~¸õ¹L'''''''''''
- Sheets("¤u§@ªí1").Activate
- Range("A1").Select
- Columns("A:A").EntireColumn.AutoFit
- Sheets("¤u§@ªí1").Activate
- End Sub
½Æ»s¥N½X |
|
Ian
|
|
|
|
|