Hello All,

I have a simple task to split a string but not able to get it to work. I am using the following line to split my input string.

#set ($Title = $test.TestTitle.split(" - ", 2))

I am having trouble directly accessing the two resultant elements in the list. Both the following come back empty.

$Title.get(0)
$Title.get(1)


I *can* get to the data using a foreach loop, but it seems a little roundabout.

   #foreach ($val in $Title)
       #if ($velocityCount == 1) #set ($Number = $val) #end
       #if ($velocityCount == 2) #set ($Name = $val) #end
   #end

Does someone know of a better way to access the information? Thank you.

gmc

---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to