UCase with Worksheet_Change and Target Address
If Target.Address = "$L$23" Then
DWSat = Range("K23")
BSat = Ucase(Range("L23").Value)
If BSat = "Y" And DWSat = 0 Then
MsgBox "You Have Turned On Your Budget. " & _
"You Must Now Set a Daily Daily Weight!", Buttons:=vbExclamation
Range("K23").Select
End If
End If
I would advise against trying to set Target to reference another cell.
--
Regards,
Tom Ogilvy
"David" wrote in message
...
If a small letter is entered into a specific cell, I need it to be upper
case
or to have the code recognize either lower or upper case for the
Worksheet_Change to fire. I've tried putting the UCase in, but nothing is
working. Here is the code without the UCase in it: I Need L23 to be
Upper Case for this to work currently.
If Target.Address = "$L$23" Then
Set Target = Range("K23")
DWSat = Range("K23")
BSat = Range("L23")
If BSat = "Y" And DWSat = 0 Then
MsgBox "You Have Turned On Your Budget. You Must Now Set a Daily
Daily Weight!", Buttons:=vbExclamation
Target.Select
End If
End If
|