StevenFlood
3/10/2019 - 10:04 AM

ADSystemInfo - Examples #Examples

ADSystemInfo - Examples #Examples

Set objSysInfo = CreateObject("ADSystemInfo")
strUser = objSysInfo.UserName
Set objUser = GetObject("LDAP://" & strUser)
Set objWord = CreateObject("Word.Application")
Objword.UserName = objuser.displayname
objWord.UserInitials = Ucase(Left(objUser.givenName, 1)) & Ucase(Left(objUser.SN, 1))
objWord.Quit