- ©«¤l
- 4901
- ¥DÃD
- 44
- ºëµØ
- 24
- ¿n¤À
- 4916
- ÂI¦W
- 255
- §@·~¨t²Î
- Windows 7
- ³nÅ骩¥»
- Office 20xx
- ¾\ŪÅv
- 150
- ©Ê§O
- ¨k
- ¨Ó¦Û
- ¥x¥_
- µù¥U®É¶¡
- 2010-4-30
- ³Ì«áµn¿ý
- 2024-11-24
|
¦^´_ 1# leoman0002 - Sub ex()
- Dim arr()
- Dim Filename As Variant
- Dim i As Integer
- fs = Application.GetOpenFilename("¶È¯à¶×¤Jcsv®æ¦¡,*.csv", , "Çë½T©w", , True) '§ï¦¨½Æ¿ïÀÉ®×
- For Each f In fs '¨CÓÀÉ®×°j°é
- p = Range("G65536").End(xlUp).Row + 1
- With CreateObject("Microsoft.XMLHTTP")
- .Open "GET", f, False
- .Send
- tt = .responsetext
- ss = Split(tt, vbCrLf)
- End With
- ReDim arr(0 To UBound(ss), 0 To 15)
- For i = 0 To UBound(ss)
- s1 = Split(ss(i), ",")
- For j = 0 To UBound(s1)
- arr(i, j) = s1(j)
- Next j
- Next i
- Cells(p, "a") = Replace(arr(5, 1), "'", "")
- Cells(p, "b") = Replace(Split(Cells(p, "a"), "-")(0), Mid(Split(Cells(p, "a"), "-")(0), 3, 5), "")
- Cells(p, "c") = Split(Cells(p, "a"), "-")(1)
- Cells(p, "G") = arr(3, 3)
- If arr(11, 7) = "Bef" Then
- Cells(p, "H") = "[Before]"
- Else
- Cells(p, "H") = "[After]"
- End If
- Cells(p, "I") = arr(11, 5)
- Cells(p, "J") = arr(11, 5)
- Cells(p, "K") = arr(20, 5)
- Cells(p, "R") = arr(21, 5)
- Cells(p, "S") = arr(22, 5)
- Cells(p, "T") = arr(23, 5)
- k = 20
- For i = 26 To 33
- For j = 1 To 3
- k = k + 1
- Cells(p, k) = arr(i, (j - 1) * 2 + 1)
- Next j
- Next i
- Next f
- End Sub
½Æ»s¥N½X |
|