Hi,
again I have strange problem, I´m not sure if I´m stupid or kix.
I read a line from a file with format like 1,2,3,4,5,6,7,8,9,10,11, into an array, I split this array with delimiter ",", this works fine no problem.
 Code:
$KSArray = Split ($KSAnzahl,",")
For Each $KSNR in $KSArray
	Gosub Tauschen
Next


The variable $KSNR contains an Value from 1 to XX which I need in the subroutine called "Tauschen". In this Subroutine a UNC Path is created to connect to a network share.

 Code:
:Tauschen
Select
	Case $KSNR < 0
	Return

	Case $KSNR <= 9
	$POS = "POS0"

	Case $KSNR >= 10 
	$POS = "POS"

EndSelect

? $Site + $POS + $KSNR
Return

The Result is:


DEU04712POS01
DEU04712POS02
DEU04712POS03
DEU04712POS04
DEU04712POS05
DEU04712POS06
DEU04712POS07
DEU04712POS08
DEU04712POS09
All fine but:



DEU04712POS010
DEU04712POS011
DEU04712POS012
....


Correct it should be
DEU04712POS11
DEU04712POS12

I tried also with if clauses, i tried with duoble quotes nothing runs like i want.

What the hell I do wrong?!