EBOOZ / TeamsStatus

Monitoring your Microsoft Teams status with PowerShell
202 stars 40 forks source link

unicode characters in USERNAME #18

Open piatkos opened 3 years ago

piatkos commented 3 years ago

Hi,

maybe it's not an issue, but I had a problem with configuration because I have polish letter in my username. Entering it to config file - breaks the script. If someone is looking for a solution - you can try to enter it in that way:

$UserName = "WojtekPi$([char]0x0105)tkowski" instead of $UserName = "WojtekPiątkowski"

Maybe adding that info to comment will help someone in future? :)

EBOOZ commented 3 years ago

Good one! Let me investigate if we can prevent this issue from happing later.

felipecrs commented 2 years ago

I did not find any good way around this, so what I'm doing is to save the Settings.ps1 file with Windows 1252 encoding.

weemaba999 commented 2 years ago

I think I have the same issue, my username is my emailadres, so I think that's why I get the UNKNOWN status all the time.

Using the unicode as @piatkos did, meaning bart.weemaels$([char]0x0040)cegeka.be doesn't work either. Path to HA is ok, running the script seperately without failures in powershell as admin, .... getting lost here

Anyone ?

mhoogenbosch commented 2 years ago

@weemaba999 the username you need is the username on your local system, there is always a 'local' user. You can see this when you type "echo %USERNAME% into your command prompt. My username for example is martijn@email.com but my local user is marti, which is autogenerated during the first logon.

To get the service running you need to execute the service with your local user, not with the service account. This doesn't work for me. With running the service under my own useraccount, it works great!