Livin404
Well-known Member
- Joined
- Jan 7, 2019
- Messages
- 774
- Office Version
- 365
- 2019
- Platform
- Windows
Greetings,
The following macro works well; however I need to make a small tweak, so the first letter will begin with a capital and the rest of the name will be lowercase. The line is
Thank you,
The following macro works well; however I need to make a small tweak, so the first letter will begin with a capital and the rest of the name will be lowercase. The line is
Excel Formula:
Cells(Target.Row, "H").Value = LCase(Split(Application.UserName, ",")(0))
Thank you,
VBA Code:
Private Sub Worksheet_Change(ByVal Target As Range)
Application.EnableEvents = False
Columns.AutoFit
If Target.Cells.Count = 1 And Target.Column = 2 Then
Cells(Target.Row, "H").Value = LCase(Split(Application.UserName, ",")(0))
End If
Application.EnableEvents = True
End Sub