°Ñ¦Òªþ¥ó¡J
http://www.FunP.Net/300415
Private Sub CommandButton1_Click()
Dim j%, k%
Sheets("DATA").Range("I6", "P" & [R6] + 6).Copy [I6] '½Æ»sI:P¸ê®Æ
Range("I" & [Q5] + 7, "P" & [R6] + 6).Copy [A7]
Range("I7", "P" & [Q5] + 6).Copy Range("A" & [Q6] + 7) '½Æ»sA:H¸ê®Æ
Cells([T5] + 6, 9).Interior.ColorIndex = 4 'IÄ檺T5´Á¼Æ¼Ð¥Ü©³¦â
If ([T5] + [Q6]) Mod [R6] > 0 Then
Cells(([T5] + [Q6]) Mod [R6] + 6, 1).Interior.ColorIndex = 8 'AÄ檺T5´Á¼Æ¼Ð¥Ü©³¦â
Else
Cells([R6] + 6, 1).Interior.ColorIndex = 8
End If
For j = 10 To 16
If Cells([T5] + 6, j) = [R5] Then '¥HIÄæT5´Á¼Æ¦³Åã¥ÜR5Ȭ°°ò·Ç±ø¥ó
If ([T5] + [Q6]) Mod [R6] = 0 Then
Cells([R6] + 6, j - 8).Interior.ColorIndex = 8
Cells([R6] + 6, j).Interior.ColorIndex = 37
With Cells([Q6] + 6, j - 8)
.Interior.ColorIndex = 8
.Font.ColorIndex = 7
.Font.FontStyle = "²ÊÅé"
End With
With Cells([Q6] + 6, j)
.Interior.ColorIndex = 37
.Font.ColorIndex = 7
.Font.FontStyle = "²ÊÅé"
End With
Else
For k = 0 To Int(([R6] - ([T5] + [Q6]) Mod [R6]) / [Q6])
Cells(([T5] + [Q6]) Mod [R6] + 6 + [Q6] * k, j - 8).Interior.ColorIndex = 8 'AÄæT5´Á¨Ì¦U¶¡¶Z¼Æ©¹¤U¼Ð¥Ü©³¦â
Cells(([T5] + [Q6]) Mod [R6] + 6 + [Q6] * k, j).Interior.ColorIndex = 37
Next k
With Cells(([R6] - ([R6] - ([T5] + [Q6]) Mod [R6]) Mod [Q6] + [Q6]) Mod [R6] + 6, j - 8) 'AÄæ=kªº³Ì«á¶¡¶Z´Á¼Æ¦A¥[¤@Ó¶¡¶Z¼Ð¥Ü©³¦â
.Interior.ColorIndex = 8
.Font.ColorIndex = 7
.Font.FontStyle = "²ÊÅé"
End With
With Cells(([R6] - ([R6] - ([T5] + [Q6]) Mod [R6]) Mod [Q6] + [Q6]) Mod [R6] + 6, j)
.Interior.ColorIndex = 37
.Font.ColorIndex = 7
.Font.FontStyle = "²ÊÅé"
End With
End If
End If
Next j
[R6].Select
End Sub
»Ý¨D
½Ð°Ý¡J
µ{¦¡½X¯à¦p¦ó¦A²¤Æ?
¥H¤W Àµ½Ð¦U¦ì«e½ú¡B¥ý¶i¤£§[½ç±Ð! ÁÂÁÂ! |