Jump to content

Command Line Parameters containing quotes


Recommended Posts

Do I have to write my own $CmdLineRaw parser, or is there a template available?

Just do your own parsing as you will need to sort the $CMDLINE parsed to the script anyway.

Example

If $CMDLINE[0] Then
    For $i = 1 To $CMDLINE[0]
        $parameter = $CMDLINE[$i]
        Select
            Case StringLeft($parameter, 2) = '/T'
                $title = StringTrimLeft($parameter, 2)
                If StringInStr($title, ' ') Then
                    $title = '"' & $title & '"'
                EndIf
            Case ; next condition
                ; ........
        EndSelect
    Next
EndIf

:)

Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
 Share

  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...