Adding Multiple Lines To Data Field

Brad_ZimaBrad_Zima Member IT Monkey ✭

I'm currently working on outputting multiple object to the Description field in a work item and was wondering how to insert a newline in between the data points? I've tried the usual `n and `r`n to no avail. Can anyone help me out?

Best Answers

Answers

  • Peter_MiklianPeter_Miklian Customer Advanced IT Monkey ✭✭✭

    @Brad_Zima this is working fine for me. Make sure you are using the right ` sign.

    Set-SCSMObject -SMObject (Get-SCSMObject -Class (Get-SCSMClass ^System.WorkItem.ServiceRequest$) -Filter "Name -eq 'SRID'") -Property Description -Value "first line`nsecond line`nthird line`t`t`taligned text"
    
  • Brad_ZimaBrad_Zima Member IT Monkey ✭

    Unfortunately, I'm using the stock data fields in an Orchestrator runbook and not a Powershell script, or are you saying this will work there as well?

  • Brad_ZimaBrad_Zima Member IT Monkey ✭

    Oh man, I had no idea the Expand option was there! I feel kind of dumb for not seeing it before. Only a half-hour into the work day and I've learned something new. Thanks guys!

Sign In or Register to comment.