Displaying special characters in PowerShell

I have tried setting different fonts and code pages in PowerShell but I cannot get the following characters to display.

$bars = [Char[]] ‘_’, ‘▂’, ‘▃’, ‘▄’ ,‘▅’, ‘▆’, ‘▇’,‘█’

The characers belong to the MS Gothic font set but setting PowerShell to use this (rather ugly) font still did not render correctly and instead displayed small hollow squares.

Any help would be appreciated :slight_smile:

The PowerShell console can’t display extended characters from double-byte character sets. The console app dates from the mid-80s.

That’s a shame. I didn’t know PowerShell was developed in the 80’s.

Why is it that Bash (a much older technology) can do this? https://github.com/holman/spark

Ugh. What did I write? The console host was written then, which is why the PowerShell team wrote the ISE for v2. If you can’t contribute positively to the conversation, at least don’t troll.

I’m not trolling, just a bit of sarcasm.

You should modify the rules of engagement to include “NO SARCASM”.

Roger.