It's not toast. However, it does have problems. The best way is to start with a script outline, then add functionality piece-by piece. Get each piece working, then add the next one.

Also, keep clean syntax and structure. Don't mix script code, subroutines, and functions. Functiosn should grouped togeter either at the very top or very bottom of a script. However, the preferred method is to have functions inside a function library, e.g. FUNCTIONS.UDF that gets included into the scirp by placing a CALL FUNCTIONS.UDF at the top of the script.

It's also good to use SETOPTION('Explicit','on') as this will catch syntax errors in variables and ensures correct scoping of variables.

It takes more time to debug sloppy code than coding in a clean and concise way fromt he very beginning.

Finally, if you copy functions from the UDF Forum, please keep the UDF Header intact.

[ 26. July 2003, 02:48: Message edited by: sealeopard ]
_________________________
There are two types of vessels, submarines and targets.