How to get $caption -join “`n” inside an array?
When I do the following, it gives me a an unexpected token error.
$captions = Get-CimInstance win32_diskdrive | select -expand caption $info = @( System Info `n "BIOS Version: $(Get-Ciminstance win32_bios | select -expand SMbiobiosversion) `n" "Baseboard: $(Get-Ciminstance win32_baseboard | select -expand product) `n" "Drives: $captions -join "`n"" $label1.Text = $info
submitted by /u/mitzenlol
[link] [comments]
The post [HELP] variable inside an array appeared first on How to Code .NET.