So, if 'S' will definitely only be 8 or 9 chars long and 'W/L' will be only 7 or 8 char long, this should work. If they could be longer, just change the $len comparison's to >7 and >6 respectively. Should work.

Code:

$nums = "1234567890"
$letters = "SNKEHMRL"
$computer = "S1253K59A"
$computerName = "Failed"
$stillGood = 1
$len = len($computer)
if instr("WLS", left($computer, 1))
if left($computer, 1) = "S" and ($len = 8 or $len = 9)
for $j = 2 to 5
if not instr($nums, substr($computer, $j, 1))
$stillGood = 0
endif
next

for $j = 7 to 8
if not instr($nums, substr($computer, $j, 1))
$stillGood = 0
endif
next

if instr($letters, substr($computer, 6, 1)) and $stillGood
$computerName = "Store"
endif
else
if $len = 7 or $len = 8
for $j = 2 to 7
if not instr($nums, substr($computer, $j, 1))
$stillGood = 0
endif
next
if $stillGood
$computerName = "Corp"
endif
endif
endif
endif

? $computerName

_________________________
Eric