Results 1 to 23 of 23

Record Changing Value for Multiple Cells

Threaded View

  1. #1
    Registered User
    Join Date
    03-13-2020
    Location
    usa
    MS-Off Ver
    win7
    Posts
    13

    Record Changing Value for Multiple Cells

    Does anyone know how would I change my code to make it work for multiple cells?

    Right now if I change the value of AG5 it returns the recorded value on AI5 and so on. I would like to change the value of AG6 and have the value at AI6 also to be changed.... and the same if I change AG7 the record value would be at AI7..( I still want to see the changes or records for each row) Thank you again in advance.


    [Dim xVal As String
    Private Sub Worksheet_Change(ByVal Target As Range)
    Static xCount As Integer
    Application.EnableEvents = False
    If Target.Address = Range("AG5").Address Then
    Range("AI5").Offset(0, xCount).Value = xVal
    xCount = xCount + 1
    Else
    If xVal <> Range("AG5").Value Then
    Range("AI5").Offset(0, xCount).Value = xVal
    xCount = xCount + 1
    End If
    End If
    Application.EnableEvents = True

    End Sub

    Private Sub Worksheet_SelectionChange(ByVal Target As Range)
    xVal = Range("AG5").Value
    End Sub]
    Last edited by asac; 12-11-2020 at 07:11 PM.

Thread Information

Users Browsing this Thread

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

Similar Threads

  1. [SOLVED] Record Changing Value in a Cell with VBA
    By asac in forum Excel Programming / VBA / Macros
    Replies: 3
    Last Post: 12-11-2020, 05:54 PM
  2. print as pdf or save as in multiple record [lookup record]
    By Jhon Mustofa in forum Excel Programming / VBA / Macros
    Replies: 2
    Last Post: 07-31-2018, 10:15 AM
  3. Record Value of Changing Forumla?
    By andre199017 in forum Excel Programming / VBA / Macros
    Replies: 8
    Last Post: 06-06-2014, 05:03 AM
  4. Replies: 14
    Last Post: 10-07-2013, 04:04 PM
  5. Continuous changing cell values - record highest and lowest values in seperate cells
    By attienel in forum Excel Programming / VBA / Macros
    Replies: 4
    Last Post: 03-11-2013, 05:12 PM
  6. Record an ever changing cells value from Sheet 1 every 30 seconds into Sheet 2
    By stejjfc in forum Excel Programming / VBA / Macros
    Replies: 4
    Last Post: 02-20-2013, 07:03 PM
  7. Record Symbols from Changing List Based on Meeting Various Criteria in Other Cells
    By DrSues02 in forum Excel Programming / VBA / Macros
    Replies: 3
    Last Post: 12-18-2007, 05:20 PM

Tags for this Thread

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