UserName Property [Excel 2003 VBA Language Reference]

Returns or sets the name of the current user. Read/write String.

Example

This example displays the name of the current user.

MsgBox "Current user is " & Application.UserName

Applies to | Application Object