- ©«¤l
- 522
- ¥DÃD
- 36
- ºëµØ
- 1
- ¿n¤À
- 603
- ÂI¦W
- 0
- §@·~¨t²Î
- win xp sp3
- ³nÅ骩¥»
- Office 2003
- ¾\ŪÅv
- 50
- ©Ê§O
- ¨k
- µù¥U®É¶¡
- 2012-12-13
- ³Ì«áµn¿ý
- 2021-7-11
|
¥ÎVBA, VBA code ¦p¤U:
Sub ²Îp©ñ°²¦W³æ()
Dim x, y As Object
Dim i, j, k As Integer
Dim str1 As String
Dim Colindx(5) As Integer
Set x = Sheets("©ñ°²¦W³æ")
Set y = Sheets("²Îpªí")
y.Range("D3:X72").ClearContents
'¦C¼Æ(i+2)¥Nªí¤é´Á
For i = 1 To 31
'Colindx(k)¥Nªí"²Îpªí"ªºÄæ¼Æp¼Æ¾¹
For k = 1 To 5
Colindx(k) = 3
Next
'Äæ¼Æ(j-2)¥Nªíû¤u¼Æ
For j = 3 To 18
str1 = x.Cells(i + 2, j)
Select Case str1
Case Is = "¡¾"
Colindx(1) = Colindx(1) + 1
y.Cells(i * 5 - 2, Colindx(1)) = x.Cells(2, j)
Case Is = "¡³"
Colindx(2) = Colindx(2) + 1
y.Cells(i * 5 - 1, Colindx(2)) = x.Cells(2, j)
Case Is = "¡·"
Colindx(3) = Colindx(3) + 1
y.Cells(i * 5, Colindx(3)) = x.Cells(2, j)
Case Is = "¡¼"
Colindx(4) = Colindx(4) + 1
y.Cells(i * 5 + 1, Colindx(4)) = x.Cells(2, j)
Case Is = "¡¸"
Colindx(5) = Colindx(5) + 1
y.Cells(i * 5 + 2, Colindx(5)) = x.Cells(2, j)
End Select
Next
Next
End Sub
©ñ°²¦W³æ¦p¤U:
²Îpªí°õ¦æµ²ªG¦p¤U:
|
|