Within the RecordSet class's
are thrown depending on the type of exception that occurred. The following code snippet shows
how this code might look.
// Within RecordSet.as class file...
function sortRows() {
...
if(recordSetErrorCondition) {
throw new RecordSetException();
}
if(malFormedRecordCondition) {
throw new MalformedRecord();
}
...
}
Finally, in another AS file or FLA script, the following code invokes the
an instance of the RecordSet class. It defines
.
sortRows()
try {
myRecordSet.sortRows();
} catch (e:RecordSetException) {
trace("Caught a recordset exception");
} catch (e:MalformedRecord) {
trace("Caught a malformed record exception");
}
See also
Error
class,
throw
738
Chapter 12: ActionScript Dictionary
sortRows()
,
,
class
extends
method, one of these previously defined error objects
blocks for each type of error that is thrown by
catch
method on
sortRows()
Need help?
Do you have a question about the FLASH MX 2004 - ACTIONSCRIPT and is the answer not in the manual?
Questions and answers