Solved

Dreamweaver cs4 classic asp dsn sql 2008 http 500 error

Posted on 2011-02-13
6
688 Views
Last Modified: 2012-08-13
Just starting out with classic asp (need to support an old website) Getting a HTTP 500 error when I add a recordset to the webpage. Works fine with an equivilent MS Access database.

Sql DSN passes test connection and passes test/shows recordset, but the very fact the recordset is attached to the page throws the error even before trying to place a field. The driver for the sql 2008R2 system dsn is sql client (have tried sql server, same problem)

Can anyone point me in the right direction, may thanks
0
Comment
Question by:downehouse
  • 3
  • 3
6 Comments
 
LVL 52

Expert Comment

by:Carl Tawn
ID: 34882584
Start by turning off "Show Friendly Http Errors" in your browser. That way you will be able to see the actual error message rather than the generic 500 message.
0
 

Author Comment

by:downehouse
ID: 34886540
Thanks, good point, but had already done this, what I had not done was to change IIS 7.5 'Send Errosrs to Browser' setting to true.  Having done this the error is with the DSN on line Recordset1_cmd.ActiveConnection. However the DSN checks out OK when tested at the created stage.

I have the following code:
<%@LANGUAGE="VBSCRIPT" CODEPAGE="65001"%>
<!--#include file="Connections/Merlin.asp" -->
<%
Dim Recordset1
Dim Recordset1_cmd
Dim Recordset1_numRows

Set Recordset1_cmd = Server.CreateObject ("ADODB.Command")
Recordset1_cmd.ActiveConnection = MM_Merlin_STRING (**** error on this line)Recordset1_cmd.CommandText = "SELECT BulletinID, BulletinDate, BulletinBody, PostedBy FROM dbo.BULLETIN"
Recordset1_cmd.Prepared = true

Set Recordset1 = Recordset1_cmd.Execute
Recordset1_numRows = 0
%>

The include file code is as follows..
<%
' FileName="Connection_odbc_conn_dsn.htm"
' Type="ADO"
' DesigntimeType="ADO"
' HTTP="false"
' Catalog=""
' Schema=""
Dim MM_Merlin_STRING
MM_Merlin_STRING = "dsn=Merlin;"
%>

Any help appreciated (Runing Dreamwearver CS4 on Win 7, with SQL server 2008 R2)
0
 
LVL 52

Expert Comment

by:Carl Tawn
ID: 34886877
What is the error?
0
Highfive + Dolby Voice = No More Audio Complaints!

Poor audio quality is one of the top reasons people don’t use video conferencing. Get the crispest, clearest audio powered by Dolby Voice in every meeting. Highfive and Dolby Voice deliver the best video conferencing and audio experience for every meeting and every room.

 

Author Comment

by:downehouse
ID: 34887058
Sorry..

error '80040e4d'

/avalon/index_tmp.asp, line 9
0
 
LVL 52

Accepted Solution

by:
Carl Tawn earned 500 total points
ID: 34887080
Have you tried with a DSN-less connection?
0
 

Author Comment

by:downehouse
ID: 34887932
Have now, it works, shame DSN would not play ball.  Thanks for the quick responses.
0

Featured Post

Highfive Gives IT Their Time Back

Highfive is so simple that setting up every meeting room takes just minutes and every employee will be able to start or join a call from any room with ease. Never be called into a meeting just to get it started again. This is how video conferencing should work!

Join & Write a Comment

This demonstration started out as a follow up to some recently posted questions on the subject of logging in: http://www.experts-exchange.com/Programming/Languages/Scripting/JavaScript/Q_28634665.html and http://www.experts-exchange.com/Programming/…
In this article we will get to know that how can we recover deleted data if it happens accidently. We really can recover deleted rows if we know the time when data is deleted by using the transaction log.
Get a first impression of how PRTG looks and learn how it works.   This video is a short introduction to PRTG, as an initial overview or as a quick start for new PRTG users.
Access reports are powerful and flexible. Learn how to create a query and then a grouped report using the wizard. Modify the report design after the wizard is done to make it look better. There will be another video to explain how to put the final p…

757 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

18 Experts available now in Live!

Get 1:1 Help Now