- ©«¤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
|
¦^´_ 6# s7659109
¦^ÂÐ ½Ð¥ý«ö ¦^ÂÐ, ¦A¦^ÂÐ,
¨Ò¦p§A§Æ±æ 6F µ¹§A¦^ÂÐ, «h¦b 6F ¤U±ªº¡i¦^ÂСj«ö¶s¤WÂI¤@¤U,
³o¼Ë 6F ªº¤H´N·|±µ¨ì¨t²Îªº³qª¾, ¦p¦¹¤~¤£·|¯Ô»~®É¶¡,
§_«h¦¬¤£¨ì§Aªº ¦^ÂÐ, ¤£ª¾§A¦³¦ó·s°ÝÃD. ÁÂÁÂ!!
1. ¦^ÂФW¤@Ó°ÝÃD¡G
ì·Qªk ±N 103¦~ ªºÄæ¦ì§R°£ ¦³»~, ¦p¦¹¤@¨Ó,
©Ò¦³ªº ¯Å¼Æ §¡À³«·s§ó·s, ¤uµ{¸û¤j,
¸û²³æªº¤èªk¬O:
±N 104¦~ ªº¤Hû°¯Å¬° 103¦~ ªº¯Å¼Æ, «h¨ä¥L¤Hûªº¯Å¼Æ§¡¤£¥Î§ó·s.
2. ¦^ÂХثe°ÝÃD¡G
Option Explicit
Private Sub Worksheet_Change(ByVal Target As Range)
Dim j, lastRow, ¯Å¼Æ1, ³Ì°ª¯Å As Integer
Dim ¼úª÷1 As Long
Dim rng As Range
Dim Ãþ§O1, ¾Ç¾ú1 As String
lastRow = [J65536].End(xlUp).Row '¨ú±oJÄæ³Ì¤U¤@¦æ
Set rng = [J3].Resize(lastRow, 1)
If Not Intersect(Target, rng) Is Nothing Then
Target.Offset(0, 1).Resize(1, 20).Clear '²M°£¶ñ¤J°Ï
¾Ç¾ú1 = Target.Offset(0, -1)
¯Å¼Æ1 = --Target.Value
³Ì°ª¯Å = Application.VLookup(¾Ç¾ú1, Range("C3:E9"), 2, 0)
¼úª÷1 = Application.VLookup(¾Ç¾ú1, Range("C3:E9"), 3, 0)
For j = 1 To 9
If j + ¯Å¼Æ1 - 2 < ³Ì°ª¯Å Then
'Target.Offset(0, j * 2) = ¼úª÷1 / 2
'Cells(¯Å¼Æ1 + j, 2) ´N¬O·í¦~Á~¤ô
Target.Offset(0, j * 2) = Cells(¯Å¼Æ1 + j, 2) * 2
Target.Offset(0, j * 2 - 1) = Cells(¯Å¼Æ1 + j, 2)
Target.Offset(0, j * 2 - 1).Resize(1, 2).Interior.ColorIndex = xlNone
Else
'Target.Offset(0, j * 2) = ¼úª÷1
Target.Offset(0, j * 2) = Cells(³Ì°ª¯Å + 1, 2) * 5
Target.Offset(0, j * 2 - 1) = Cells(³Ì°ª¯Å + 1, 2)
Target.Offset(0, j * 2 - 1).Resize(1, 2).Interior.ColorIndex = 38
End If
Next
End If
End Sub
¤£¹L¥Ø«e¤½©w¦³³o»ò¦n±d¶Ü? |
|