This is part of a Command line parsing function that I have put together for a script. But when I compile and run the script I get a Kixtart ERROR
ERROR: Error in Expression: this type of array not supported in expression !
-script name-
Line 4
The line in question is the SELECT command which is confusing since if anything I would expect the error to be in the CASE stmt. And I've tried multiple variations of that line just in case it was that line, but no luck.
I've put in code to check how the SPLIT Command is parsing the commandline and it's output is what I expect
Command
option1
option2
optionN
Has anyone run into anything similar?
CODE ========================================
Function CmdLineParse()
Dim $CmdLine[20]
$CmdLine = Split($EXECmdLine, " ", -1)
For Each $parm In $CmdLine
Select
Case InStr($opt, "/computer=") <> 0
$x = Trim(Right(InStr($parm, "=")))
$_computer = Trim(Right($parm, Len($parm) - $x))
Case InStr($CmdLine, "/repository=") <> 0
$x = Trim(Right(InStr($parm, "=")))
$_repository = Trim(Right($parm, Len($parm) - $x))
Case 1
? "Unknown Parameter" + $parm
EndSelect
Next
EndFunction
_________________________
----------------------------------------------------------------------------------------
NOTE: Regardless of content, this post shall not operate to bind CSC to any order or other contract unless pursuant to explicit written agreement or government initiative expressly permitting the use of posts for such purpose.
----------------------------------------------------------------------------------------