Forum Discussion
chenrylee
Jul 11, 2019Brass Contributor
The Format of Teams Setting File desktop-config.json
Hello, I have a question on Teams setting file desktop-config.json. In the company, after installing Teams we must do some preset settings, for example, prevent Teams from auto-starting with sy...
JonasFr
Aug 06, 2019Copper Contributor
chenrylee
Hi,
maybe a bit late but check the how the coding of the .json file output is.
The .json written back to file system most probably contains BOM (Byte Order Marks) which the original file doesn't!
You can check this if you look at the file in HEX. If your file starts with EF BB BF byte order marks are set for your file.
Teams is ignoring this file and will overwrite it with its default.
One way to provide is using a .NET function as there is no BOM set:
$jsonObject = ConvertTo-Json -InputObject $psConfigObject -Depth 4 -Compress
[System.IO.File]::WriteAllLines($configFilepath, $jsonObject )
Hope this helps!
Best regards,
JF