Elaborating A VB IF senario

rouzacct

Board Regular
Joined
Aug 31, 2010
Messages
65
Hello

i currently have this code to help me see what date/time/user a cell in the ("R:R") had its value changed.
----------------------------------
Private Sub Worksheet_Change(ByVal Target As Range)
If Not Intersect(Target, Range("R:R")) Is Nothing Then
Target.Offset(0, 1) = Now
Target.Offset(0, 2) = Environ("UserName")

End If
End Sub
-------------------------------------

I would like to elaborate it a little

it would be great to have date and time separated
so that when a cell in ("R:R") is changed
the 3 cells on its right "S-T-U" auto populate date/time/user

there are 4 words that could be written in that column

if "RET" i would like it to auto populate date/time/user in the next 3 columns "S-T-U" and also in 3 other columns on the right (any 3 columns next to each other i will check the offsets after )

if "PROBLEM" i would like it to auto populate date/time/user in the next 3 columns "S-T-U" and also in 3 other columns on the right (any 3 columns next to each other i will check the offsets after)

IF "DEAD" i would like it to auto populate date/time/user in the next 3 columns "S-T-U" and also in 3 other columns on the right (any 3 columns next to each other i will check the offsets after)

IF "GOOD" i would like it to auto populate date/time/user in the next 3 columns and also in 3 other columns on the right (any 3 columns next to each other i will check the offsets after)

so that

It always shows the last date/time/user that a cell in R:R was changed in "S-T-U" but also keeps a record of the last status by doubling up the date/time/user into separate columns by RET - PROBLEM - DEAD - GOOD
and not overriding the date/time/user of the last change from any of the words.

ANY HELP WOULD BE GREATLY APPRECIATED
 

Excel Facts

Create a chart in one keystroke
Select the data and press Alt+F1 to insert a default chart. You can change the default chart to any chart type

Forum statistics

Threads
1,225,155
Messages
6,183,215
Members
453,151
Latest member
Lizamaison

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 MrExcel.com.
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 "mrexcel.com".
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
Back
Top