Information générale
Catégorie:
The Mere Mortals .NET Framework
Versions des environnements
Network:
Windows 2003 Server
Hi Tim,
Thanks for your reply. Are you saying that in order to display a meaningful exception message to the user in a graceful way that I will need to add Try Catch code somewhere? Where?
Sam
>I would agree with Randy here in that only catching and reporting database errors is a bit of an ineffiecient way to do this. When you wrap your mm Save in a Try Catch you will catch an error which will give you a string result of your database issue. It would be better and more efficient to call the child business object to retrieve all child records for that parent and see if there are any rows returned. This might even be faster than dealing with a caught exception.
>
>I would still leave my database constraint in place however, so I would think you need both.
>Just my thoughts also.
>Tim
Précédent
Suivant
Répondre
Voir le fil de ce thread
Voir le fil de ce thread à partir de ce message seulement
Voir tous les messages de ce thread
Voir tous les messages de ce thread à partir de ce message seulement