Link to home
Start Free TrialLog in
Avatar of chicabow
chicabow

asked on

retreive data from access - try and catch?

I am building pages similiar to the concept behind this page listed here. http://support.microsoft.com/default.aspx?scid=kb;EN-US;q308100&GSSNB=1
I was wondering if try and catch statements should be used in the pages, I always though it is standard practice to include this. Why isnt it used in this example?
What is the strandard protocol and process for this?

Or does it not merrit adding this since  its just a query of data?

Avatar of Carl Tawn
Carl Tawn
Flag of United Kingdom of Great Britain and Northern Ireland image

Because they're being lazy :o)

You'll find a lot of samples don't bother putting the try...catch in there so that you concentrate on the specific concept they are trying to demonstrate.
Avatar of chicabow
chicabow

ASKER

Looking for some more concrete answer if possible anyone?
ASKER CERTIFIED SOLUTION
Avatar of Carl Tawn
Carl Tawn
Flag of United Kingdom of Great Britain and Northern Ireland image

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
Slight correction:

         if (cn.State != ConnectionState.Closed)
             cn.Close();
Thanks for the reminder, these are helpful for people who foget to close them out.

Thanks Carl_Tawn