Consulting

Results 1 to 4 of 4

Thread: Solved: whats the difference

  1. #1
    VBAX Expert CatDaddy's Avatar
    Joined
    Jun 2011
    Posts
    581
    Location

    Solved: whats the difference

    whats the difference between

    Worksheet_SelectionChange(ByVal Target As Range)

    and

    Worksheet_Change(ByVal Target As Range)
    ------------------------------------------------
    Happy Coding my friends

  2. #2
    VBAX Sage
    Joined
    Apr 2007
    Location
    United States
    Posts
    8,728
    Location
    If the Active Cell is A1 and you click A2, that's a "SelectionChange"

    If the Active Cell is A1 and has 100 in it, and you change A1 to 200 and hit enter, that's a "Change"

    Either can happen either via KB or VBA

    More details in online help: "worksheet object events"


    Paul

  3. #3
    VBAX Expert CatDaddy's Avatar
    Joined
    Jun 2011
    Posts
    581
    Location
    thank you!
    ------------------------------------------------
    Happy Coding my friends

  4. #4
    Knowledge Base Approver VBAX Wizard
    Joined
    Apr 2012
    Posts
    5,645
    In
    Worksheet_SelectionChange(ByVal Target As Range)

    Target is the cell you enter

    and

    in
    Worksheet_Change(ByVal Target As Range)

    Target is the cell you 'left' (where the change took place).

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •