Le Sat, 11 Feb 2006 19:54:01 +0100, Jim Ault <[EMAIL PROTECTED]> a écrit:

On 2/11/06 10:32 AM, "Girard Damien" <[EMAIL PROTECTED]> wrote:

Hi all,

I am making some useful library for my softwares, and I have got one
problem.

How I return an error ?

Because when I use "return", this doesn't work very great.

on hellotest theNumber
   if isnumber(theNumber) is false then
     return "error"
   end if
   ...
end hellotest
 You could try
on hellotest theNumber
   if isnumber(theNumber) is false then
     return isnumber(theNumber)
   end if


but I don't know how useful this would be.
What error message do you want to return?

Jim Ault
Las Vegas


I wan't to return a specific error message (internaly in Runrev), I wrote complex commands, who call a lot of subcommands and functions, and when an error is uncountered, I wan't to return it. The advantage is to permit to the developers to understand why there is an error. And this permit to the software to manage these errors. (For exemple, you call a command
in a try structure, and you can manage this error with catch).

--

Girard Damien
_______________________________________________
use-revolution mailing list
[email protected]
Please visit this url to subscribe, unsubscribe and manage your subscription 
preferences:
http://lists.runrev.com/mailman/listinfo/use-revolution

Reply via email to