Welcome!

By registering with us, you'll be able to discuss, share and private message with other members of our community.

SignUp Now!

Error handling in plugins

May
120
1
What is best practice for argument validation in plugins? If I have a
plugin command with arguments, say

MYPLUGIN [/A] [/B arg]

how should I handle an unexpected argument /D? (Built in commands seem
to report a (Sys) error including the incorrect flag, how do I
replicate this?) What about /B with a missing argument, or /A with
extra arguments?

If anyone has published a plugin with source which could serve as an
example of argument handling good practice, that would be brilliant!

Paul.
 
I published the EVENT plugin with source code. If you download it from
the JPsoft website, you'll get the source.

-Scott

"p.f.moore" <> wrote on 07/09/2008 11:02:26 AM:


> What is best practice for argument validation in plugins? If I have a
> plugin command with arguments, say
>
> MYPLUGIN [/A] [/B arg]
>
> how should I handle an unexpected argument /D? (Built in commands seem
> to report a (Sys) error including the incorrect flag, how do I
> replicate this?) What about /B with a missing argument, or /A with
> extra arguments?
>
> If anyone has published a plugin with source which could serve as an
> example of argument handling good practice, that would be brilliant!
>
> Paul.
>
 

Similar threads

Back
Top