CurrentUserName Property Example

This example displays a message box containing the name of the current Microsoft Office user.

MsgBox "The current Microsoft Office user is " & _
    CurrentUserName