- ©«¤l
- 561
- ¥DÃD
- 160
- ºëµØ
- 0
- ¿n¤À
- 725
- ÂI¦W
- 0
- §@·~¨t²Î
- WINDOWS
- ³nÅ骩¥»
- xp
- ¾\ŪÅv
- 50
- ©Ê§O
- ¨k
- ¨Ó¦Û
- ®ç¶é
- µù¥U®É¶¡
- 2014-9-10
- ³Ì«áµn¿ý
- 2024-8-7
|
1.¥ÎVBA¤ñ¸û§Ö ¦p¤U
1.1SHEET2=ªí¤G ²Ä¤@¦C¦Û¦æ©ñ¼ÐÃD.
AÄæ¥N¸¹¡BBÄæ©m¦W¡BCÄæ¼úª÷¥H¤ÎDÄ檺¿n¤À
1.2SHEET1=ªí¤@¸ê®Æ®w
AÄæ¥N¸¹¡BBÄæ©m¦W¡BEÄæ¼úª÷¥H¤ÎUÄ檺¿n¤À
1.3«Ø¥ß«ö¶s°õ¦æ¤U¤èµ{¦¡
Sub DATA()
Sheet2.[A265536].ClearContents
Y = Sheet2.[A65536].End(xlUp).Row + 1
X = Sheet1.[A65536].End(xlUp).Row
For M = 2 To X
If Sheet1.Cells(M, 21) - 25 >= 0 And Sheet1.Cells(M, 21) - 40 <= 0 Then
Sheet2.Cells(Y, 1) = Sheet1.Cells(M, 1)
Sheet2.Cells(Y, 2) = Sheet1.Cells(M, 2)
Sheet2.Cells(Y, 3) = Sheet1.Cells(M, 5)
Sheet2.Cells(Y, 4) = Sheet1.Cells(M, 21)
Y = Y + 1
End If
Next
Sheet2.Select
Range("A1").Select
End Sub |
|