? getCurrentUser() function getCurrentUser() local loWMIService, loWBEMLocator, lcDomain, loCSs, loCS lcUser = 'N/A' try loWBEMLocator = createObject("wbemScripting.SwbemLocator") loWMIService = loWBEMLocator.ConnectServer() catch loWMIService = null endtry if not Isnull(loWMIService) loCSs = loWMIService.ExecQuery('Select UserName from Win32_ComputerSystem') for each loCS in loCSs lcUser = loCS.UserName exit endfor endif return lcUserlcUser will have the "domain\username" format, from where you can parse both