Forum Discussion

phillip_bradbur's avatar
phillip_bradbur
New Contributor
11 years ago

Sys.OSInfo.TempDirectory truncation of user names

While attempting to utilize Sys.OSInfo.TempDirectory, I obtained truncation of my username, which happens to be longer than 8 characters.



The path returned is reminiscent of the days of Windows 98.  Instead of "C:\Users\pbradbury\AppData\Local\Temp\", I get "C:\Users\pbradb~1\AppData\Local\Temp\".



This is truncation is unnecessary and not helpful.  There is a workaround that I am currently using:



aqEnvironment.GetEnvironmentVariable("UserProfile", False) &  \AppData\Local\Temp\" & fileName



However, this is unwieldy when there is a shortcut within Sys.OSInfo (that is also referenced by documentation).

1 Reply


  • Hi Phillip,


     


    Launching TestComplete as an Administrator may help you avoid getting ~ in the path.