³Â»¶®a±Ú°Q½×ª©ª©'s Archiver

wang077 µoªí©ó 2021-6-21 16:48

¤@¦C¥u¯à¦³¤­­Ó¼Æ­È

[i=s] ¥»©«³Ì«á¥Ñ wang077 ©ó 2021-6-21 16:51 ½s¿è [/i]

¦U¦ì¤j¯«½Ð°Ý
[attach]33436[/attach]
§Ú¦p¦ó¥ÎVBAôJ­ì¥»ª½ªº1~15
¨C¤­­Ó¼Æ­È±Æ¤@¦æ

samwang µoªí©ó 2021-6-22 08:32

[i=s] ¥»©«³Ì«á¥Ñ samwang ©ó 2021-6-22 08:33 ½s¿è [/i]

[b]¦^´_ [url=http://forum.twbts.com/redirect.php?goto=findpost&pid=115396&ptid=23178]1#[/url] [i]wang077[/i] [/b]

¤£¦n·N«ä¹ï¤å¦r²z¸Ñ¤£¤Ó¦n¡A¬Ý¤F¦üÀ´«DÀ´¡A½Ð°Ý³W«h¬°¦ó? ¥i§_¦A¥[»¡©ú¸Ô²Ó©Îªþ¤W¸Ñµª¡AÁÂÁ¡C

¨C¤­­Ó¼Æ­È±Æ¤@¦æ: ¶Ã¼Æ¡A¥i­«½Æ...

samwang µoªí©ó 2021-6-22 11:17

[b]¦^´_ [url=http://forum.twbts.com/redirect.php?goto=findpost&pid=115396&ptid=23178]1#[/url] [i]wang077[/i] [/b]

½Ð´ú¸Õ¬Ý¬Ý¡AÁÂÁ¡C

Sub test()
Dim Arr, Ar(1 To 3)
Arr = Range([a1], [a65536].End(3))
y = 2
For i = 1 To UBound(Arr)
    For j = 1 To 3
        N = N + 1: If N > UBound(Arr) Then GoTo 99
        Ar(j) = Arr(N, 1)
    Next
    Cells(1, y).Resize(3, 1) = Application.Transpose(Ar)
    y = y + 1
99: Next
End Sub

hcm19522 µoªí©ó 2021-6-22 16:09

[url]https://blog.xuite.net/hcm19522/twblog/589846795[/url]

wang077 µoªí©ó 2021-6-22 19:14

[b]¦^´_ [url=http://forum.twbts.com/redirect.php?goto=findpost&pid=115399&ptid=23178]2#[/url] [i]samwang[/i] [/b]
¥´¿ù¤F À³¸Ó¬O3­Ó¼Æ­È¤@¦æ¡AµM«á­­¨î³Ì¦h5¦æ¡A¼Æ­È¤£¤@©w¬O1¡ã15¡A¤W­±¹Ï¤ù¥u¬O¥Ü·N¹Ï

wang077 µoªí©ó 2021-6-22 19:17

[b]¦^´_ [url=http://forum.twbts.com/redirect.php?goto=findpost&pid=115406&ptid=23178]4#[/url] [i]hcm19522[/i] [/b]
¦³¿ìªk¨Ï¥Îvba¨Ó°µ¶Ü

samwang µoªí©ó 2021-6-22 19:45

[b]¦^´_ [url=http://forum.twbts.com/redirect.php?goto=findpost&pid=115410&ptid=23178]5#[/url] [i]wang077[/i] [/b]


¤£¦n·N«ä¡A¯uªº¤£¯à²z¸Ñ±zªº»Ý¨D¡A©ÎªÌ±z¥i¥Hªþ¤W¦³¸ÑµªªºÀÉ®×¥B»¡©ú¸Ô²Ó±ø¥ó³W«h¡A·PÁ¡C

wang077 µoªí©ó 2021-6-22 23:28

[b]¦^´_ [url=http://forum.twbts.com/redirect.php?goto=findpost&pid=115403&ptid=23178]3#[/url] [i]samwang[/i] [/b]
For i = 1 To UBound(Arr)
³o¬qÅã¥Ü¸ê®Æ«¬ºA¿ù»~

wang077 µoªí©ó 2021-6-22 23:35

[b]¦^´_ [url=http://forum.twbts.com/redirect.php?goto=findpost&pid=115411&ptid=23178]6#[/url] [i]wang077[/i] [/b]
[attach]33442[/attach]
´N¬O¨Ò¦p¹Ï¤ù
§ÚAÄ椤ªº¼Æ­È
­n§â¥¦¤À¦¨¤­¦æ¨Ó±Æ¦C
±Æ¦C¤è¦¡A1:A3ªº¼Æ­È¦bB1:B3
A4:A6ªº¼Æ­È¦bC1:C3
¥H¦¹Ãþ±À¡C

samwang µoªí©ó 2021-6-23 07:17

[b]¦^´_ [url=http://forum.twbts.com/redirect.php?goto=findpost&pid=115417&ptid=23178]9#[/url] [i]wang077[/i] [/b]


3¼Óµ{¦¡½X¨S°ÝÃD¦pªþ¥ó¡A½Ð¦A´ú¸Õ¬Ý¬Ý¡AÁÂÁ¡C

wang077 µoªí©ó 2021-6-23 15:34

[b]¦^´_ [url=http://forum.twbts.com/redirect.php?goto=findpost&pid=115418&ptid=23178]10#[/url] [i]samwang[/i] [/b]
¤j¯«
[attach]33448[/attach]
¦pªGAÄæ¼Æ­È¦³N­Ó©O?
¦Ó¥B³Ì¦h±Æ5­ÓÄæ¦ì¦Ó¤w

samwang µoªí©ó 2021-6-23 16:47

[b]¦^´_ [url=http://forum.twbts.com/redirect.php?goto=findpost&pid=115432&ptid=23178]11#[/url] [i]wang077[/i] [/b]

½Ð¦A´ú¸Õ¬Ý¬Ý¡AÁÂÁÂ

Sub test1()
Dim Arr, Ar(1 To 3)
Arr = Range([a1], [a65536].End(3))
[color=Red]x = 1: [/color]y = 2
For i = 1 To UBound(Arr)
    For j = 1 To 3
        N = N + 1: If N > UBound(Arr) Then GoTo 99
        Ar(j) = Arr(N, 1)
    Next
    Cells(x, y).Resize(3, 1) = Application.Transpose(Ar)
    [color=Red]If y < 6 Then[/color] y = y + 1 [color=Red]Else x = x + 3: y = 2[/color]
99: Next
End Sub

wang077 µoªí©ó 2021-6-23 16:54

[b]¦^´_ [url=http://forum.twbts.com/redirect.php?goto=findpost&pid=115434&ptid=23178]12#[/url] [i]samwang[/i] [/b]
¤j¯«¡A¥i¯à§Úªí¹F¤£²M·¡
§Úªº·N«ä¬OA1:A4ªº¼Æ­È¦bB1:B4
A5:A8ªº¼Æ­È¦bC1:C4
A9:A12ªº¼Æ­È¦bD1:D4
A13:A16ªº¼Æ­È¦bE1:E4
A17:A20ªº¼Æ­È¦bF1:F4

samwang µoªí©ó 2021-6-23 17:24

[b]¦^´_ [url=http://forum.twbts.com/redirect.php?goto=findpost&pid=115435&ptid=23178]13#[/url] [i]wang077[/i] [/b]


¦]¬°±zªº³W«h¤£©ú½T¦³°ÝÃD¡A²{¦b»Ý¨DAÄæ¦ì¥u¨ì20µ§
¦pªGAÄæ¦ì°²³]¶W¹L20µ§¥H«á¡A­n«ç»ò³B²z??

wang077 µoªí©ó 2021-6-23 18:28

[b]¦^´_ [url=http://forum.twbts.com/redirect.php?goto=findpost&pid=115436&ptid=23178]14#[/url] [i]samwang[/i] [/b]
´N¬O¤£ºÞAÄ榳´Xµ§¸ê®Æ
³Ì¦h¥u¯à¥Î5­ÓÄæ¦ì¨Ó±Æ§Ç
¤]´N¬OB-FÄæ

samwang µoªí©ó 2021-6-23 20:29

[b]¦^´_ [url=http://forum.twbts.com/redirect.php?goto=findpost&pid=115437&ptid=23178]15#[/url] [i]wang077[/i] [/b]

½Ð¦A´ú¸Õ¬Ý¬Ý¡AÁÂÁÂ

Sub test2()
Dim Arr, Ar(), N%, M%, x%, y%
Arr = Range([a1], [a65536].End(3))
M = Int(UBound(Arr) / 5): x = 1: y = 2
If M < 1 Then
    Cells(x, y).Resize(, UBound(Arr)) = Application.Transpose(Arr)
Else
    For i = 1 To UBound(Arr)
        ReDim Ar(1 To M)
        If N = UBound(Arr) Then GoTo 99
        If N = M * 5 Then
            ReDim Ar(1 To UBound(Arr) - N)
            For j = 1 To UBound(Arr) - N: N = N + 1: Ar(j) = Arr(N, 1): Next
            Cells(x, y).Resize(, UBound(Ar)) = Ar: Exit For
        End If
        For j = 1 To M: N = N + 1: Ar(j) = Arr(N, 1): Next
        Cells(x, y).Resize(UBound(Ar), 1) = Application.Transpose(Ar)
        Erase Ar
        If y < 6 Then y = y + 1 Else x = x + M: y = 2
99: Next
End If
End Sub

wang077 µoªí©ó 2021-6-23 20:57

[b]¦^´_ [url=http://forum.twbts.com/redirect.php?goto=findpost&pid=115440&ptid=23178]16#[/url] [i]samwang[/i] [/b]
´ú¸Õ¹L¤F¡A¨S°ÝÃD¡C
·PÁ¤j¯«À°¦£¡A¨¯­W¤F¡C

wang077 µoªí©ó 2021-6-25 09:31

[b]¦^´_ [url=http://forum.twbts.com/redirect.php?goto=findpost&pid=115440&ptid=23178]16#[/url] [i]samwang[/i] [/b]
Sub Openfile()
fileToOpen = Application _
        .GetOpenFilename("Excel Files(*.csv*), *.csv*", MultiSelect:=True)
        num = 0
        linenumber = 0
    For num1 = 1 To UBound(fileToOpen)
    num = num + 1
    If fileToOpen(num) <> "False" Then
    Open fileToOpen(num) For Input As #1 ' Open file for input
    Do While Not EOF(1) ' Loop until end of file
        linenumber = linenumber + 1
        Line Input #1, line
        arrayOfElements = Split(line, ",")
        elementnumber = 0
        For Each element In arrayOfElements
            elementnumber = elementnumber + 1
            Cells(linenumber, elementnumber).Value = element
        Next
    Loop
    End If
Close #1 ' Close file.
Next num1
End Sub
³o¬O§Úªºµ{¦¡½X¡A¶}¥X¨ÓªºcsvÀɳ£¬O¶Ã½X
¥Î¤F¿ý¼v¥¨¶°
µo²{¸òTextFilePlatform¦³Ãö
¤j¯«¥i¥HÀ°§Ú¶Ü

samwang µoªí©ó 2021-6-25 09:44

[b]¦^´_ [url=http://forum.twbts.com/redirect.php?goto=findpost&pid=115468&ptid=23178]18#[/url] [i]wang077[/i] [/b]

¤£¦n·N«ä¡A¤£¤Ó¼ô±xCSVÀɮ׳o³¡¤À¡A«Øij¥i¥H¨ìExcel µ{¦¡°Ïµo¤å¡A¨ºùØ°ÝÃD¤ñ¸û¦h¤H¦bÃöª`©Î³\¥i¸Ñ±zªº°ÝÃD¡A·PÁ¡C

wang077 µoªí©ó 2021-6-25 09:54

[b]¦^´_ [url=http://forum.twbts.com/redirect.php?goto=findpost&pid=115469&ptid=23178]19#[/url] [i]samwang[/i] [/b]
¦nªº¡A·PÁ±z

­¶: [1] 2

³Â»¶®a±Ú°Q½×ª©ª©¬° ³Â»¶¾Ç¶é ºô¯¸¦¨­û  ¥Ñ ¬R±o¸ê°T¤u§@«Ç © Since 1993 ©Ò´£¨Ñ