VBA §Ç¸¹¶W¹L12½X¼Æ¦r¦p¦ó¥H¼Æ¦C¤è¦¡©¹¤U¶ñº¡
- ©«¤l
- 70
- ¥DÃD
- 9
- ºëµØ
- 0
- ¿n¤À
- 83
- ÂI¦W
- 27
- §@·~¨t²Î
- win
- ³nÅ骩¥»
- 7
- ¾\ŪÅv
- 20
- ©Ê§O
- ¤k
- µù¥U®É¶¡
- 2024-2-3
- ³Ì«áµn¿ý
- 2024-11-16
|
VBA §Ç¸¹¶W¹L12½X¼Æ¦r¦p¦ó¥H¼Æ¦C¤è¦¡©¹¤U¶ñº¡
§Úªº§Ç¸¹¶W¹L12½X¼Æ¦r¦p¦ó¥H¼Æ¦C¤è¦¡©¹¤Uµ¥¥[¤@¶ñº¡
§Ç¸¹®i¶}.zip (27.15 KB)
|
|
|
|
|
|
|
- ©«¤l
- 1447
- ¥DÃD
- 40
- ºëµØ
- 0
- ¿n¤À
- 1471
- ÂI¦W
- 0
- §@·~¨t²Î
- Windows 7
- ³nÅ骩¥»
- Excel 2010 & 2016
- ¾\ŪÅv
- 50
- ©Ê§O
- ¨k
- ¨Ó¦Û
- ¥xÆW
- µù¥U®É¶¡
- 2020-7-15
- ³Ì«áµn¿ý
- 2024-12-3
|
¥»©«³Ì«á¥Ñ Andy2483 ©ó 2024-2-17 16:46 ½s¿è
¦^´_ 1# aassddff736
ÁÂÁ«e½úµoªí¦¹¥DÃD»P½d¨Ò
¾Ç²ß¤è®×¦p¤U,½Ð«e½ú°Ñ¦Ò
Private Sub CommandButton1_Click()
Dim T$, Q$, Brr, V&
T = Trim([A1]): V = Val(TextBox1.Value): If V = 0 Or T = "" Then Exit Sub
ReDim Brr(1 To V, 1 To 1)
Q = StrReverse(Mid(Val(StrReverse(T & "1")), 2))
T = Replace(T, Q, "")
For i = 0 To V - 1: Brr(i + 1, 1) = T & (Val(Q) + i): Next
[A1].Resize(V) = Brr
End Sub |
|
¥Î¦æ°Ê¸Ë¸mÂsÄý½×¾Â¾Ç²ß«Ü¤è«K,ÁÂÁ½׾¸gÀç¹Î¶¤
½Ð¤j®a¤@°_¤W½×¾Â¨Ó¥æ¬y
|
|
|
|
|
- ©«¤l
- 70
- ¥DÃD
- 9
- ºëµØ
- 0
- ¿n¤À
- 83
- ÂI¦W
- 27
- §@·~¨t²Î
- win
- ³nÅ骩¥»
- 7
- ¾\ŪÅv
- 20
- ©Ê§O
- ¤k
- µù¥U®É¶¡
- 2024-2-3
- ³Ì«áµn¿ý
- 2024-11-16
|
¦^´_ 2# Andy2483
·PÁ¤j¯«
§Úª¦¤å«Ü¤[ ¨S§ä¨ì
«D±`¶}¤ß±zªºÀ°¦£
±z¯uªº¬O§Úªº¯« |
|
|
|
|
|
|
- ©«¤l
- 70
- ¥DÃD
- 9
- ºëµØ
- 0
- ¿n¤À
- 83
- ÂI¦W
- 27
- §@·~¨t²Î
- win
- ³nÅ骩¥»
- 7
- ¾\ŪÅv
- 20
- ©Ê§O
- ¤k
- µù¥U®É¶¡
- 2024-2-3
- ³Ì«áµn¿ý
- 2024-11-16
|
¦^´_ 2# Andy2483
½Ð°Ý¤j¯«
§Úªº½X¼Æ¯à¸òA1¨Ì¼Ë¶Ü?0001¤£nÅܦ¨1 |
|
|
|
|
|
|
- ©«¤l
- 1447
- ¥DÃD
- 40
- ºëµØ
- 0
- ¿n¤À
- 1471
- ÂI¦W
- 0
- §@·~¨t²Î
- Windows 7
- ³nÅ骩¥»
- Excel 2010 & 2016
- ¾\ŪÅv
- 50
- ©Ê§O
- ¨k
- ¨Ó¦Û
- ¥xÆW
- µù¥U®É¶¡
- 2020-7-15
- ³Ì«áµn¿ý
- 2024-12-3
|
¦^´_ 4# aassddff736
ÁÂÁ«e½ú¦^´_
«á¾Çקï»P¾Ç²ß¤ß±o¦p¤U,½Ð«e½ú°Ñ¦Ò
°õ¦æ«e:
°õ¦æµ²ªG:
Private Sub CommandButton1_Click()
Dim T$, Q$, Brr, V&, L%
'¡ô«Å§iÅܼÆ
T = Trim([A1]): V = Val(TextBox1.Value): If V = 0 Or T = "" Then Exit Sub
'¡ô¥OTÅܼƬO[A1]Àx¦s®æ¥h°£ÀY§À«áªº·s¦r¦ê,¥OVÅܼƬO¤å¦rµ¡¿é¤JÈÂà¤Æ¦¨ªº¼ÆÈ
'¦pªGVÅܼƬO0 ©ÎTÅܼƬOªÅ¦r¤¸,´Nµ²§ôµ{¦¡°õ¦æ
Intersect(Me.UsedRange, [A:A]).Offset(1).ClearContents
'¡ô¥O[A2]¶}©l¥H¤UªºÀx¦s®æ²M°£¤º®e
ReDim Brr(1 To V, 1 To 1)
'¡ô«Å§iBrrÅܼƬO¤GºûªÅ°}¦C
Q = Val(StrReverse(T & "1")): Q = StrReverse(Mid(Q, 2)): L = Len(Q)
'¡ô¥OQÅܼƬO T¦r¦ê³Ì«áªº³sÄò¼Æ¦r¦ê,¥OLÅܼƬOQÅܼƪº¦r¤¸¼Æ
T = Replace(T, Q, "")
'¡ô¥OTÅܼÆÅܦ¨¦Ü´«±¼QÅܼƫ᪺·s¦r¦ê
For i = 0 To V - 1: Brr(i + 1, 1) = T & Application.Text(Val(Q) + i, String(L, "0")): Next
'¡ô³]¶¶°j°é!¥OiÅܼƱq0 ¨ìVÅܼÆ-1,±N°j°é·s¦r¦ê¼g¤JBrr°}¦C¤¤
[A1].Resize(V) = Brr
'¡ô¥O±q[A1]Àx¦s®æ¶}©l¦V¤UÂX®iVÅܼÆÓÀx¦s®æ½d³ò,¥HBrr°}¦Cȼg¤J
End Sub |
|
¥Î¦æ°Ê¸Ë¸mÂsÄý½×¾Â¾Ç²ß«Ü¤è«K,ÁÂÁ½׾¸gÀç¹Î¶¤
½Ð¤j®a¤@°_¤W½×¾Â¨Ó¥æ¬y
|
|
|
|
|
- ©«¤l
- 70
- ¥DÃD
- 9
- ºëµØ
- 0
- ¿n¤À
- 83
- ÂI¦W
- 27
- §@·~¨t²Î
- win
- ³nÅ骩¥»
- 7
- ¾\ŪÅv
- 20
- ©Ê§O
- ¤k
- µù¥U®É¶¡
- 2024-2-3
- ³Ì«áµn¿ý
- 2024-11-16
|
¦^´_ 5# Andy2483
ÁÂÁ±zªº²Ó¤ß«ü¾É
§Ú«Ü·Q¾Ç·|VBA ¥Ø«e¥¿¦b¾Ç°ò¦ ÁÂÁ±z!
¦pªG§Úªº§Ç¸¹¬O"0001"®i¶}·|ÅÜ"1"§Ún¦p¦óÅý¥¦¤£ÅÜ°Ê ³]¦¨¤å¦r®æ¬O¶Ü? |
|
|
|
|
|
|
- ©«¤l
- 1447
- ¥DÃD
- 40
- ºëµØ
- 0
- ¿n¤À
- 1471
- ÂI¦W
- 0
- §@·~¨t²Î
- Windows 7
- ³nÅ骩¥»
- Excel 2010 & 2016
- ¾\ŪÅv
- 50
- ©Ê§O
- ¨k
- ¨Ó¦Û
- ¥xÆW
- µù¥U®É¶¡
- 2020-7-15
- ³Ì«áµn¿ý
- 2024-12-3
|
¦^´_ 6# aassddff736
¿ï¨úA:A
|
|
¥Î¦æ°Ê¸Ë¸mÂsÄý½×¾Â¾Ç²ß«Ü¤è«K,ÁÂÁ½׾¸gÀç¹Î¶¤
½Ð¤j®a¤@°_¤W½×¾Â¨Ó¥æ¬y
|
|
|
|
|
- ©«¤l
- 70
- ¥DÃD
- 9
- ºëµØ
- 0
- ¿n¤À
- 83
- ÂI¦W
- 27
- §@·~¨t²Î
- win
- ³nÅ骩¥»
- 7
- ¾\ŪÅv
- 20
- ©Ê§O
- ¤k
- µù¥U®É¶¡
- 2024-2-3
- ³Ì«áµn¿ý
- 2024-11-16
|
¦^´_ 7# Andy2483
ÁÂÁ«ü±Ð |
|
|
|
|
|
|