One of my basic coding rules is a function should never be longer than a page.

Each function should have a description of what it does and an example of its syntax.

As I mentioned before I think that a function or series of functions could be developed and placed into its own class that would handle all of the exceptions for arguments.

I would be interested in discussing this and coming up with a class for handling that.

That way the handling of the exceptions would not cloud the example, and the exception codes would be generated, and it would be easy to add exception handling to any routine.

Function specification

As I see it, the array of arguments, an array holding the data types for each argument, array of optional (default values) and a flag that would tell the routine to display the error messages to the command line in AutoCAD, the console in the development environment, record them into a file, or do not display them at all also maybe a protection mode that helps the data types to strings etc...

I could see the function returning an array of arguments or (nothing) before moving on through the routine.

Also one of friends at AU (Scott McFarlane) in his lecture emphasized the need to not mix AutoCAD dependent functions with other generic functions.

I interpreted that and applied that to LISP functions and pure .NET functions.

I prefer to make the LISPMethod function call the pure .NET function.

Do you have any suggestions or opinions on these ideas?

DO you have any robust exception handling functions?