- ©«¤l
- 5923
- ¥DÃD
- 13
- ºëµØ
- 1
- ¿n¤À
- 5986
- ÂI¦W
- 0
- §@·~¨t²Î
- win10
- ³nÅ骩¥»
- Office 2010
- ¾\ŪÅv
- 150
- ©Ê§O
- ¨k
- ¨Ó¦Û
- ¥xÆW°ò¶©
- µù¥U®É¶¡
- 2010-5-1
- ³Ì«áµn¿ý
- 2022-1-23
|
¥»©«³Ì«á¥Ñ GBKEE ©ó 2013-6-24 16:23 ½s¿è
¦^´_ 11# vzcen
B5ªº®æ¦¡´N¤£¥²×§ï¤F
B5ªº¤º®e·|Åã¥Ü¦¨102903, ¦¹¬°6¦ì¼Æ,½Ð°Ý B5, 10ÂI¥H«e·|Åã¥Ü¦¨95959, ¦¹¬°5¦ì¼Æ- Option Explicit
- Private Sub Worksheet_Calculate()
- Dim Rng As Range
- Static Msg As Boolean '¥H Static ³¯z¦¡«Å§iªºÅܼơA¦bµ{¦¡°õ¦æ´Á¶¡¡A·|¤@ª½«O¯d¤º®e¡C
- ' If Time < #10:28:00 AM# Or Time > #1:30:00 PM# Then Exit Sub '«DÀç·~¤é ©Î «DÀç·~®É¶¡
- If Msg = False Then
- ²M°£Â¸ê®Æ
- Msg = True
- End If
- With Cells(Rows.Count, "C").End(xlUp)
- If .Row = 7 Then
- Set Rng = .Offset(1)
- Else
- Set Rng = .Cells
- End If
- End With
- 'If Rng = "" Or Rng.Text <> Mid([B5].Text, 1, IIf(Len([B5]) = 6, 4, 3)) Then '¦pªG[B5]10ÂI¥H«eªºªº¼ÆȬO95959, 5¦ì¼Æ ¥Î¦¹µ{¦¡½X
- If Rng = "" Or Rng.Text <> Mid([B5].Text, 1, 4) Then
- If Rng <> "" Then Set Rng = Rng.Offset(1)
- With Rng
- .NumberFormatLocal = "@"
- '.Cells = Mid([B5].Text, 1, IIf(Len([B5]) = 6, 4, 3)) '¦pªG[B5]10ÂI¥H«eªºªº¼ÆȬO95959. 5¦ì¼Æ ¥Î¦¹µ{¦¡½X
- .Cells = Mid([B5].Text, 1, 4)
- .Cells(1, 2) = [B6].Text
- .Cells(1, 3) = [B6].Text
- End With
- 'ElseIf Rng.Text = Mid([B5].Text, 1, IIf(Len([B5]) = 6, 4, 3)) Then '¦pªG[B5]10ÂI¥H«eªºªº¼ÆȬO95959. 5¦ì¼Æ ¥Î¦¹µ{¦¡½X
- ElseIf Rng.Text = Mid([B5].Text, 1, 4) Then
- If [B6] > Rng(1, 2) Then Rng(1, 2) = [B6].Text
- If [B6] < Rng(1, 3) Then Rng(1, 3) = [B6].Text
- End If
- End Sub
½Æ»s¥N½X- Private Sub ²M°£Â¸ê®Æ()
- On Error GoTo Er
- If [Àç·~¤é] <> Date Then 'Àˬd ©w¸q¦WºÙ:"Àç·~¤é"ªºÈ
- Me.Names.Add "Àç·~¤é", Date '©w¸q¦WºÙ:"Àç·~¤é"ªºÈ¬°·í¤é
- If Weekday(Date, vbMonday) <= 5 Then Range([C8], [E8].End(xlDown)).Clear ' קï 3#
- End If
- Exit Sub
- Er: '³B¸Ì: ¨S¦³©w¸q¦WºÙ:"Àç·~¤é"ªº¿ù»~
- Me.Names.Add "Àç·~¤é", Date '©w¸q¦WºÙ:"Àç·~¤é"ªºÈ¬°·í¤é
- Resume Next '¦^¨ì¿ù»~ªº¤U¤@Óµ{¦¡½X:Ä~Äò°õ¦æ
- End Sub
½Æ»s¥N½X |
|