gettingstarted
[Top] [All Lists]

Handling OutOfBoundsException

To: Getting Started <gettingstarted at lists dot realsoftware dot com>
Subject: Handling OutOfBoundsException
From: Paul Young <youngpr at myactv dot net>
Date: Fri, 25 Feb 2005 09:47:55 -0500
Delivered-to: gettingstarted at lists dot realsoftware dot com
I'm using RB 5.5.4 on a Mac with OS 10.3.8.
I'm writing a simple utility to fill a ListBox with data from an AddressBook: Name, email address and telephone number. Some contacts do not include the telephone number data and I get an "OutOfBoundsException" error even though I use the following code at the end of the Method:

...
Exception err
        If err isA OutOfBoundsException then
                MsgBox "No data available."
        End if
End Sub

The Language Reference says the above should prevent the application from quitting after the MsgBox is closed. How should I handle the case where the desired data is not present?

Thanks,

Paul

_______________________________________________
Unsubscribe or switch delivery mode:
<http://www.realsoftware.com/support/listmanager/>

Search the archives of this list here:
<http://www.realsoftware.com/listarchives/lists.html>

<Prev in Thread] Current Thread [Next in Thread>