on run
try
set une_variable to 123
my main()
on error errText number errNr
if errNr = -128 then
return
else if errNr = -2700 then
tell application "Mail" to display dialog errText buttons {"OK"} default button 1
else
"Error = " & errNr & return & errText
display dialog the result buttons {"OK"} default button 1
end if
end try
end run -------------------------------------------------------
on main()
set une_variable to une_variable + 1
end main -------------------------------------------------------
If you run it you will get an error message because une_variable
which is defined in the run handler is local to this one
and is not seen by the handler main().