+ Reply to Thread
Results 1 to 4 of 4

Worksheet_Change(ByVal Target As Range) - set to only update when 3 target cells changed?

  1. #1
    Registered User
    Join Date
    08-08-2010
    Location
    Ottawa, Canada
    MS-Off Ver
    Excel 2010
    Posts
    85

    Worksheet_Change(ByVal Target As Range) - set to only update when 3 target cells changed?

    Hi!

    I have seen similar posts for this however when I tried to employ the suggestions/code it wouldn't work for me.

    I have an excel book that has a form that users need to fill out and then "sign" to say they have done what they were suppsed to do.

    What I want to have happen is that when they select 3 different cells on this tab, different rows hide or unhide etc. Right now the only way I can get it to run is to do it through <<Private Sub Worksheet_Change(ByVal Target As Range)>>.

    But this means that when other actions happen on this tab (i.e. other buttons/macros run, other cells have data entered into them) the this private sub macro is continually firing.

    How can I make it fire ONLY when either or both of these 3 "target" cells are changed? These cells are E6 (named as "TypeofWork"), E7 (named "AddClientLine") and S43 (named "TotalTriggers").

    Any help would be much appreciated!

    Please Login or Register  to view this content.
    Last edited by trillium; 11-07-2012 at 01:41 PM.

  2. #2
    Forum Guru xladept's Avatar
    Join Date
    04-14-2012
    Location
    Pasadena, California
    MS-Off Ver
    Excel 2003,2010
    Posts
    12,378

    Re: Worksheet_Change(ByVal Target As Range) - set to only update when 3 target cells chang

    You can't stop it from firing but you can make it switch right back:

    Please Login or Register  to view this content.
    If I've helped you, please consider adding to my reputation - just click on the liitle star at the left.

    ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~(Pride has no aftertaste.)

    You can't do one thing. XLAdept

    ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~aka Orrin

  3. #3
    Registered User
    Join Date
    08-08-2010
    Location
    Ottawa, Canada
    MS-Off Ver
    Excel 2010
    Posts
    85

    Re: Worksheet_Change(ByVal Target As Range) - set to only update when 3 target cells chang

    Thanks for the tip!

  4. #4
    Forum Guru xladept's Avatar
    Join Date
    04-14-2012
    Location
    Pasadena, California
    MS-Off Ver
    Excel 2003,2010
    Posts
    12,378

    Re: Worksheet_Change(ByVal Target As Range) - set to only update when 3 target cells chang

    You're welcome!

+ Reply to Thread

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Bookmarks

Posting Permissions

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

Search Engine Friendly URLs by vBSEO 3.6.0 RC 1