How can I create a macro that whenever I type "y" or "Y" in "O" column, it run a macro. thx.
S saman110 via OfficeKB.com Jan 11, 2008 #1 How can I create a macro that whenever I type "y" or "Y" in "O" column, it run a macro. thx.
J Jim Thomlinson Jan 11, 2008 #2 This code is worksheet event code so it must be posted into the sheet. Right click the approporate tab and select View Code. Paste the following... Private Sub Worksheet_Change(ByVal Target As Range) If Target.Column = 15 And UCase(Target.Value) = "Y" Then MsgBox "Run your macro" End If End Sub
This code is worksheet event code so it must be posted into the sheet. Right click the approporate tab and select View Code. Paste the following... Private Sub Worksheet_Change(ByVal Target As Range) If Target.Column = 15 And UCase(Target.Value) = "Y" Then MsgBox "Run your macro" End If End Sub