PSU 2.3.1
Hi,
I’m reading in content from a file to Code Editor and now I’m wondering if it’s possible to do the break on the end of the line so it get a new row? For now it do read in the file as one big line.
Here is my code:
New-UDGrid -Spacing '1' -Container -Content {
# $GetInstallationlogg = [System.IO.File]::ReadLines("PathTOLog\LogFile.log")
if ([string]::IsNullOrEmpty($GetInstallationlogg)) {
New-UDGrid -Item -Size 12 -Content {
New-UDAlert -Severity 'error' -Text "Kunde inte läsa ut loggfilen!"
}
}
else {
New-UDGrid -Item -Size 12 -Content {
Add-UDElement -ParentId 'InstallationLogFileEditor' -Content {
[System.IO.File]::ReadLines("PathTOLog\LogFile.log")
}
New-UDCodeEditor -Id 'InstallationLogFileEditor' -ReadOnly -Height 450 #-Code "$GetInstallationlogg"
}
}
}