Certain string in cell A1 causes a change in Cell B1
Hi,
may be this
Private Sub Worksheet_Change(ByVal Target As Range)
If InStr(1, Range("A1"), "Mont", vbTextCompare) 0 Then
Application.EnableEvents = False
Range("B1").Value = "This is the responsibility of...)"
Else
Range("B1").ClearContents
End If
Application.EnableEvents = True
End Sub
--
Mike
When competing hypotheses are otherwise equal, adopt the hypothesis that
introduces the fewest assumptions while still sufficiently answering the
question.
"andreashermle" wrote:
Dear Experts:
I would like to run a macro with the following requirements.
As soon as the cell value in A1 changes and the string "Mont" is part
of the cell value in A1, the Contents of B1 is to change to "This is
the responsibility of...). If this not the case nothing is to be
displayed in Cell B1
Help is much appreciated. Thank you very much in advance.
Regards, Andreas
.
|