I'm having issues changing the user initials with my vba code. This code works for changing the application.username, and then I would like to change the initials based on cell A41 (it runs a formula based on A40 to get initials based on Last, First).
EDIT: I have found a way of changing it, but need help with "Find" in VBA, see comment #3 for code.
cell A41 is
=IF(A40="","",CONCATENATE(MID(A40, FIND(",", A40, 1) + 2, 1), LEFT(A40, 1)))
Sub ChangeUserName()
On Error GoTo errHandler
Application.username = username
Sheets("requirements").Range("A40") = Application.username
errHandler:
Exit Sub
End Sub
Thank you!
Justin
Bookmarks