Thread
:
HOW TO PROMPT MSGBOX JUST ONCE
View Single Post
#
4
Posted to microsoft.public.excel.programming
Don Guillett
external usenet poster
Posts: 10,124
HOW TO PROMPT MSGBOX JUST ONCE
I don't understand what you are doing and why this way but try this.
Private Sub Worksheet_Change(ByVal Target As Range)
If UCase(Range("k24")) = "NOT AUTHORISED" Then Exit Sub
Application.EnableEvents = False
If Range("K24").Value < "NOT AUTHORISED" Then
Range("M4").Value = "AUTHORISED"
MsgBox "THANKS FOR AUTHORISATION", vbInformation, "AUTHORISED"
Range("B27").Select
End If
Application.EnableEvents = True
End S
--
Don Guillett
Microsoft MVP Excel
SalesAid Software
"K" wrote in message
...
Hi all, i have macro in Sheet Module (see below)
Private Sub Worksheet_Change(ByVal Target As Range)
If Range("K24").Value < "NOT AUTHORISED" Then
Range("M4").Value = "AUTHORISED"
MsgBox "THANKS FOR AUTHORISATION", vbInformation, "AUTHORISED"
Range("B27").Select
End If
End Sub
the macro above works fine but problem is that if any user go again
after sheet get Authorised and do some changes in sheet the MsgBox pop
up again. Is it not possible that when some one put some thing in cell
"K24" the MsgBox pop up just once but if some one go againg in the
sheet and do some changing doesnt matter in what cell including "K24"
then MsgBox should not pop up. Please can any one have any idea that
how can i stop MsgBox to appear more that one time. Please note that i
dont want to protect sheet as some time user have to change things
after it get Authorise.
Reply With Quote
Don Guillett
View Public Profile
Find all posts by Don Guillett