A family of Microsoft spreadsheet software with tools for analyzing, charting, and communicating data.
Something like this:
- Copy this code.
- Right-Click the sheet tab of interest.3) Select "View Code"4) Paste the code into the window that appears.5) Save the file as a macro-enabled .xlsm file.6) Make changes as needed
Private Sub Worksheet_Change(ByVal Target As Range) If Target.Cells.Count > 1 Then Exit Sub If Target.Column <> 3 Then Exit Sub 'only check cells in column C If Application.UserName <> "Ramirez, Pierson" Then 'only you can can make the change in column C
End If 'Turn off events to keep out of loops Application.EnableEvents = False Target.Offset(0, 1).Value = Application.UserName & " " & Now 'Turn events back on to get ready for the next change Application.EnableEvents = True'Turn off events to keep out of loops Application.EnableEvents = False Application.Undo MsgBox "You """ & Application.UserName & """ don't have permission to change that cell." 'Turn events back on to get ready for the next change Application.EnableEvents = True Exit Sub
End Sub