Friends,
After I removed the "@error=0" script worked.
The following script will Ctreate new home directories for the users and map to the P drive (insted of Z drive). Thanks for all your help.

md "\\myt-1001\home\@userid"
USE p: /DELETE
USE p: "\\myt-1001\@USERID"