Convert string value

This topic contains 3 replies, has 4 voices, and was last updated by Profile photo of Daniel Krebs Daniel Krebs 1 year, 5 months ago.

Viewing 4 posts - 1 through 4 (of 4 total)
  • Author
  • #24719
    Profile photo of Vinod Kumar
    Vinod Kumar


    I have an string that needs to be converted to upper case using powershell through command line. Say something like this

    Powershell.exe -ExecutionPolicy Bypass -NoLogo -NonInteractive -NoProfile "string" toupper()

    Is it possible ?


    Profile photo of Sean Quinlan
    Sean Quinlan

    Looks like the parser for this forum doesn't like the syntax of the command. See here for the line –

    Profile photo of Wilfredo Perez
    Wilfredo Perez

    Try something like this ("String").ToUpper() from the powershell command line

    Profile photo of Daniel Krebs
    Daniel Krebs

    Below works for me from a command prompt:

    PowerShell.exe -ExecutionPolicy Bypass -NoLogo -NonInteractive -NoProfile -Command "'String'.ToUpper()"

    If you need to use for PowerShell for something then it would probably make sense to convert your complete process to a PowerShell script instead of relying on just the output.

Viewing 4 posts - 1 through 4 (of 4 total)

You must be logged in to reply to this topic.