1. A

    Run-time Error '50290' on Worksheet Change Macro

    On one PC I have the following code fails and raises the '50290' run-time error. The model range is a data validation dropdown list on the same worksheet. If I remove the data validation, it works. What is causing the list to hang the process on this one PC? This script previously worked for...
  2. R

    VBA , To consolidate two worksheet_chang events or to add events to another one

    I appreciate you all in advance. I realized that two or more worksheet_change events can't run in a single worksheet module when I finished writing code. Once before, I asked in here and some kind guys helped me and I could finish writing code. However, I have no idea what to do to consolidate...
  3. M

    Combine Two Worksheet_Change

    HI I would like to combine two VBA codes but 1 works the other one does not :( I need the first code to monitor the two columns in the last code. Hope someone can help Dim xRg As Range Dim xChangeRg As Range Dim xDependRg As Range Dim xDic As New Dictionary Private Sub Worksheet_Change(ByVal...
  4. H

    Private Sub Worksheet_Change(ByVal Target As Range) Not working

    Hi, I am trying to trigger Macros according to the value cell A2 of Sheet1 is changed to. After changing the value in A2 nothing seems to be happening. What am I missing? Cell A2 is merged with everything up to cell B7, but I have also tried without the cell being merged. Private Sub...
  5. M

    VBA for Calling Cell in Row Range and Writing to Same Row but Different Column for Multiple Rows

    Not sure if the title is fully clear on what im asking for as i am new to using VBA in excel but essentially I am looking to add in a date field to a cell in the same row but in a different column that is consistent. I feel like there is some way of seeing the selected cell in the range and...
  6. C

    How to target Worksheet_change() on only a specific named column of a table in the sheet

    Hi Hope to have some advice on this problem. In worksheet "Work" I have a table named "tbl_work" which contains named columns "colA", "colB", "colC".... I want something to happen only when changes occur in "colB". Private Sub Worksheet_Change(ByVal Target As Range) Application.EnableEvents =...
  7. Jaafar Tribak

    Worksheet_Change(ByVal Target As Range): How was the Target Range changed ?

    Hi all, Worksheet_Change(ByVal Target As Range) The worksheet change event tells us which Range (Target) was edited but doesn't tell us how. As we know, the user can change a cell either, by editing it with the keyboard, by pasting a value into it ,by drag and drop or by using the autofill...
  8. D

    Worksheet_Change when user Drags File Handle or Copy/Paste Multiple

    I have the following Worksheet_Change code that works perfectly when a single cell in the target range is changed (B11:B & LastUsedRow). However, the code fails when a user copy/pastes multiple values or drags the file handle to pull a string down the cells. I've hit a mental roadblock on...
  9. L

    VBA Worksheet_Change Not Firing

    Hi all, I'm a VBA beginner and have been following this youtube video () by Excel for Freelancers to make a template similar to my needs. At about the 48 minute mark, this private sub was made to prevent a user from editing more than one cell at once: Private Sub Worksheet_Change(ByVal...
  10. O

    Multiple Private Sub Worksheet_Change

    Hello, I need help with combining these two codes into the Worksheet_Change sub, I can get them to work on their own but can't combine them properly. In the first sub I am ensuring users enter a date in the date field when entering data in other columns in the row: If Target.Cells.Count > 1...
  11. J

    Excel 365 - Private Sub Worksheet_Change (ByVal Target As Range) not working/triggering

    Hi, I have an old excel file (XLSB) that I wrote to help others understand how VLookups actually work, as I kept getting the same questions about 'Why is it not working this time when I have done everything the same', this will have been created in about 2013/2014. Within the file I have a...
  12. D

    Worksheet Change

    Morning all I was very kindly provided the code below which produces a message should the value of one cell (row 39) exceed the value of another (row 41) as users change data in a column. That works great. What I would like to do is change it ever so slightly in that I would like the message...
  13. R

    Run Macro whenever this cell changes

    When I run Macro1, in my worksheet, it performs a goal-seek process then stops. I want to repeat this macro one time whenever a change is made to Cell C14. I think this is a worksheet_change event. I have tried repeatedly, but unfortunately, my knowledge and skill-set are inadequate to write...
  14. N

    VBA: Subtract date after cell change

    This is my initial code out of confusion with how Worksheet_Change works Private Sub Worksheet_Change(ByVal Target As Range) With ThisWorkbook.Sheets("Home") If Target.Address = "$B$4" And Not IsEmpty(.Range("B4", "B1", "B2").Value) Then .Range("C1").Value =...
  15. C

    Applying Worksheet_Change to lots of sheets

    Hello all, I have a workbook in which there are a large number of sheets - most of which are "Person Sheets" - duplicates of the same sheet, containing data about various people. You can differentiate the "person sheets" from the other sheets as they have an x in cell B1. Anyway, I need to...
  16. Johnny Thunder

    VBA Help - Combine 2 Worksheet_Change Events - Excel 2016

    Hi group, So I have two Worksheet_Change Events written out but I realized today that you can only have one per page so here is the code, can anyone suggest a revision to combine the two into one so that I can wrap up this project...
  17. Z

    Pass Worksheet_Change Target Value to Userform

    Hello All, Here is my situation. I have a Worksheet_Change Event that tracts when Range AC has data entered. I have a YesNo message box that pops up asking the user if they want a special document to be drafted. If they select yes, then a userform will pop up with three option select and a...
  18. W

    change trigger from Worksheet_Change to Woorksheet_Calaculate

    I'm trying to change the trigger from Worksheet_Change to worksheet_calculate cannot get it to work. Private Sub Worksheet_Change(ByVal target As Range) If target.Cells.Count <> 1 Then Exit Sub If target.Address <> "F13" Then Exit Sub If (target.Value >= 0) And (target.Value < 0) ThenExit...
  19. M

    MERGE TWO Worksheet_Change codes

    Hi, I am trying to merge two VBA codes; Code1: Private Sub Worksheet_Change(ByVal Target As Range) ' If Target cell is B6 then... If Target.Column = 6 Then ' Clear contents of E6 Target.Offset(0, 1).ClearContents ' Clear contents of H6 Target.Offset(0...
  20. M

    Worksheet_Change private sub Run-time Error when deleting cell values

    The code below is acting as expected... If user enters "Personal" in any cell in Column J, cells on the same row in Columns K & L auto-fill with "Personal" If user enters either "Misc." or "Other Meals" in Column K, cells on the same row in column L auto-fill with the same word HOWEVER, any...

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back