Eureka Moment Wiki

One eureka moment at the time

User Tools

Site Tools


windows:scripting:ps_new_line

Differences

This shows you the differences between two versions of the page.

Link to this comparison view

windows:scripting:ps_new_line [2017/08/10 13:00] (current)
Line 1: Line 1:
 +====== New line in PowerShell string ====== 
 +Append "​`n"​ to the end of the string. 
 +Or use the following function 
 +<code powershell |AppendNewLine>​ 
 +function AppendNewLine { 
 +    $tmpData += $args[0] + $args[1] 
 +    $tmpData += "​`n"​ 
 +    return $tmpData 
 +
 +$string += AppendNewLine "​Parameter"​ "​Value"​ 
 +$string += AppendNewLine "​Parameter1"​ "​Value1"​ 
 +</​code>​
windows/scripting/ps_new_line.txt · Last modified: 2017/08/10 13:00 (external edit)