Exit
  • Global community
    • Language:
      • Deutsch
      • English
      • Español
      • Français
      • Português
  • 日本語コミュニティ
  • 한국 커뮤니티
0

Catching Timeout Database errors?

Guest
Jan 15, 2010 Jan 15, 2010

Occasionally, when the database on my host server is slow, people will get the following error.

Microsoft OLE DB Provider for SQL Server error '80040e31'  Timeout expired  /searchresults.asp, line 54

It destroys the page and the only thing on the page is the above error. This is really something I'd like to avoid. I would rather have a page that would appear that would appologize to the customer, tell them to come back at a later date and contact tech support to tell us about is.

So basically, if it runs into this, I would like it to either refresh to an error page or display the page without the database content and show the tech support content that was hidden with an if statement.

I suspect the solution for this is a server solution and if the server gets this error, it displays a page.

The site runs on IIS 7 with a MS-SQL 2008 database. Classic ASP (VBscript).

TOPICS
Server side applications
630
Translate
Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines

correct answers 1 Correct answer

LEGEND , Jan 15, 2010 Jan 15, 2010

Classic ASP error handling is not very full featured, but you can do it. You need to use the On Error Resume Next statement:

http://www.aspdev.org/articles/asp-error-handling/

Translate
LEGEND ,
Jan 15, 2010 Jan 15, 2010
LATEST

Classic ASP error handling is not very full featured, but you can do it. You need to use the On Error Resume Next statement:

http://www.aspdev.org/articles/asp-error-handling/

Translate
Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines