Is the database and the asp.net application is hosted on the same location or they are on different servers????
If they are on same location then you can use the SQLConnection to check whether the database server exists or not.
You can go to the link below to understand it more better
http://www.dotnetperls.com/sqlconnection[
^]
:)