If you just want the numeric prefix you can go very simple:
 Code:
$sServerPfx=Val(%LOGONSERVER%)
USE M: "\\" + $sServerPfx + "fnp01\data"