Thanks Thanks:  0
Likes Likes:  0
Results 1 to 3 of 3

Thread: Wierd One Here >>>>

  1. #1
    Board Regular
    Join Date
    Mar 2002
    Location
    Cincinnati, Ohio, USA
    Posts
    6,824
    Post Thanks / Like
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    Default

    Hi.
    Writing a procedure to cause a cell to blink if certain conditions are not met...
    However, a double-click in any cell causes the procedure to stop???

    See:
    http://www.mrexcel.com/board/viewtop...6567&forum=2&5

    Code Here:




    Private Sub Worksheet_Change(ByVal Target As Range)
    If Target.Address = "$A$1" Then
    If Target.Value < 10 Then
    BlinkBlink Sheet1.Range("A1")
    End If
    End If
    End Sub

    Sub BlinkBlink(BlinkingRange As Range)
    Dim Start
    Do Until BlinkingRange.Value >= 10
    Start = Timer
    Do While Timer < Start + 1
    If Timer = 0 Then Start = Timer
    DoEvents
    Loop
    If BlinkingRange.Interior.ColorIndex = 3 Then
    BlinkingRange.Interior.ColorIndex = 0
    Else: BlinkingRange.Interior.ColorIndex = 3
    End If
    Loop
    End Sub



    Thanks,
    Tom

  2. #2
    MrExcel MVP Ivan F Moala's Avatar
    Join Date
    Feb 2002
    Location
    Auckland, New Zealand
    Posts
    4,209
    Post Thanks / Like
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    Default

    Hi Tom ??
    Not too sure but apparently if you are in some sought of edit mode eg doubleclick
    or formula edit / cell edit THEN IF the
    Timer passes the Start value the function
    call is RESET....not sure why ??
    Will have a look further (time pemitting)

    Just a side note: Sometimes you discover
    different things when you least expect it.
    Perhaps this could be used to your advantage
    on something else ??
    Just as an example Xl97 / Userform:- I found
    that exercuting a call to displaying the Help
    About ms excel caused the Userform to become
    Non Modal !! so I didn't have to do any API
    calls ......No one could explain it. I even
    asked John Walkenback....

    I'll keep this in mind...may come in handy.

    Kind Regards,
    Ivan F Moala From the City of Sails

  3. #3
    Board Regular
    Join Date
    Mar 2002
    Location
    Cincinnati, Ohio, USA
    Posts
    6,824
    Post Thanks / Like
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    Default

    Thanks for the reply Ivan

Some videos you may like

User Tag List

Like this thread? Share it with others

Like this thread? Share it with others

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •