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

[µo°Ý] Excel VBA ½Ð¯q

[µo°Ý] Excel VBA ½Ð¯q

¥»©«³Ì«á¥Ñ zz0660 ©ó 2021-8-5 00:15 ½s¿è

1.JPG
2021-8-5 00:15

2.JPG
2021-8-5 00:15


¦³¨â­Ó¤u§@ªí¡A¤@­ÓAA¡A¥t¤@­ÓZZ¡AAA¤u§@ªíªºM1¬°¤U©Ô¿ï³æ(1~10)ªº¼Æ¦r¡A·íAA ¤u§@ªíªºÀx¦s®æO10©ÎP10©ÎQ10©ÎR10(¥|­Ó®æ¤l¥u¦³¨ä¤¤¤@­Ó·|¦³­È)¡A¦³­È®É·íM1¤U©Ô¿ï³æ=1®É¡A´N±N­È¶Ç¨ìZZªºK4&K5ªºÀx¦s®æ¡C

·íM1¤U©Ô¿ï³æ=2®É¡A´N±N­È¶Ç¨ìZZªºK6&K7ªºÀx¦s®æ¡A¦p¤U¹Ï©Ò¥Ü¡C
5.JPG
2021-8-5 00:13

6.JPG
2021-8-5 00:13


·íM1¤U©Ô¿ï³æ=3®É¡A´N±N­È¶Ç¨ìZZªºK8&K9ªºÀx¦s®æ¡C

ªþÀÉ®× QQA.rar (10.97 KB)

QQA.zip (20.71 KB) ¦^´_ 1# zz0660

TOP

¦^´_ 1# zz0660


    ¬Q¤Ñ¤Ö¥[¤F¤@­Ó ¹LÂo
­«¶ÇÀɮפ@¦¸ QQA v1.zip (17.58 KB)

TOP

ALT-F11 ¶}±ÒVB½s¿è
¿ï¾Ü ¤u§@ªí1(AA) ¶K¤W¤U¦Cµ{¦¡

Private Sub Worksheet_Change(ByVal Target As Range)
    If Target.Address(0, 0) = "M1" Then
        For Each xV In Range("O10:R10")
            If xV > 0 Then
                [ZZ!K4:K99] = ""
                [ZZ!K4].Offset((Target.Value - 1) * 2).Resize(2) = xV
            End If
        Next
    End If
End Sub
{...} ªí¥Ü»Ý­n¥Î CTRL+SHIFT+ENTER ¤TÁä¿é¤J¤½¦¡

TOP

        ÀR«ä¦Û¦b : ¤H¥Í¨S¦³©Ò¦³Åv¡A¥u¦³¥Í©Rªº¨Ï¥ÎÅv¡C
ªð¦^¦Cªí ¤W¤@¥DÃD