none
Private Sub Worksheet_Change(ByVal Target As Range) RRS feed

  • Question

  • Private Sub Worksheet_SelectionChange(ByVal Target As Range)

     If Worksheet("Sheet1").Range("I26:N26").Select Then
    Call my macro

    Thursday, November 2, 2017 1:08 PM

All replies

  • Does this do what you want?

    Private Sub Worksheet_SelectionChange(ByVal Target As Range)
        If Not Intersect(Range("I26:N26"), Target) Is Nothing Then
            Call NameOfYourMacro
        End If
    End Sub

    Replace NameOfYourMacro with the actual name of your macro.


    Regards, Hans Vogelaar (http://www.eileenslounge.com)


    Thursday, November 2, 2017 3:19 PM
  • Hi Hans,
    Is Insersect Dutch for Intersect?

    '---
    Jim Cone
    Friday, November 3, 2017 2:51 AM
  • Thanks, Jim. It was just a typo. I have corrected my previous reply.

    Regards, Hans Vogelaar (http://www.eileenslounge.com)

    Friday, November 3, 2017 8:42 AM