Hi, I get this error .... I have seen it posted before but no-one seems to have a solution so I am posting it again. I have pinged IIS, set permissions in folders, reset IIS. Any help appreciated

HTTP 500.100 - Internal Server Error - ASP error
Internet Information Services

Technical Information (for support personnel)
Error Type:
Microsoft OLE DB Provider for ODBC Drivers (0x80004005)
[Microsoft][ODBC Microsoft Access Driver] Disk or network error.
/Newland/TMP3lqyi8vswq.asp, line 24

Hi, I get this error .... I have seen it posted before but no-one seems to have a solution so I am posting it again. I have pinged IIS, set permissions in folders, reset IIS. Any help appreciated

Hi,
Thanks for your reply. Firstly let me say that I get this same error with whatever I do. I have got XP w/ SP 2, the latest MDAC 2.81 and Jet drivers with SP 8. Also I have stopped and re-started IIS. In the last instance I have downloaded a tutorial from Dreamweaver itself to try to discover and compare the problem. A database is created using "Access" and then a recordset/connection is made to it using an OLEDB script dowloaded from Connections.com so I presume it works however here it is ["Provider=Microsoft.Jet.OLEDB.4.0;Data Source=C:\Documents and Settings\Robby\My Documents\local_sites\Newland\database\users.mdb;User Id=;Password=;"] When I test the connection in DW everything is OK but I never understand why the connection only works for the "Local Machine" option and not the "Testing Server" option which is also my local machine. I dont know if that is a clue ? Anyway here is the code from register.asp

<%@LANGUAGE="VBSCRIPT"%>
<!--#include file="Connections/User_Auth.asp" -->
<%
Dim MM_editAction
MM_editAction = CStr(Request.ServerVariables("SCRIPT_NAME"))
If (Request.QueryString <> "") Then
  MM_editAction = MM_editAction & "?" & Server.HTMLEncode(Request.QueryString)
End If

' boolean to abort record edit
Dim MM_abortEdit
MM_abortEdit = false
%>
<%
' *** Redirect if username exists
MM_flag = "MM_insert"
If (CStr(Request(MM_flag)) <> "") Then
  Dim MM_rsKey
  Dim MM_rsKey_cmd

  MM_dupKeyRedirect = "registration_failed.asp"
  MM_dupKeyUsernameValue = CStr(Request.Form("username"))
  Set MM_rsKey_cmd = Server.CreateObject ("ADODB.Command")
  MM_rsKey_cmd.ActiveConnection = MM_User_Auth_STRING
  MM_rsKey_cmd.CommandText = "SELECT username FROM tbl_users WHERE username = ?"
  MM_rsKey_cmd.Prepared = true
  MM_rsKey_cmd.Parameters.Append MM_rsKey_cmd.CreateParameter("param1", 200, 1, 50, MM_dupKeyUsernameValue) ' adVarChar
  Set MM_rsKey = MM_rsKey_cmd.Execute
  If Not MM_rsKey.EOF Or Not MM_rsKey.BOF Then 
    ' the username was found - can not add the requested username
    MM_qsChar = "?"
    If (InStr(1, MM_dupKeyRedirect, "?") >= 1) Then MM_qsChar = "&"
    MM_dupKeyRedirect = MM_dupKeyRedirect & MM_qsChar & "requsername=" & MM_dupKeyUsernameValue
    Response.Redirect(MM_dupKeyRedirect)
  End If
  MM_rsKey.Close
End If
%>
<%
If (CStr(Request("MM_insert")) = "frm_register") Then
  If (Not MM_abortEdit) Then
    ' execute the insert
    Dim MM_editCmd

    Set MM_editCmd = Server.CreateObject ("ADODB.Command")
    MM_editCmd.ActiveConnection = MM_User_Auth_STRING
    MM_editCmd.CommandText = "INSERT INTO tbl_users (firstName, lastName, username, pwd, address1, city, state_province, zip_postal, country, userGroup) VALUES (?, ?, ?, ?, ?, ?, ?, ?, ?, ?)" 
    MM_editCmd.Prepared = true
    MM_editCmd.Parameters.Append MM_editCmd.CreateParameter("param1", 202, 1, 50, Request.Form("firstName")) ' adVarWChar
    MM_editCmd.Parameters.Append MM_editCmd.CreateParameter("param2", 202, 1, 50, Request.Form("lastName")) ' adVarWChar
    MM_editCmd.Parameters.Append MM_editCmd.CreateParameter("param3", 202, 1, 50, Request.Form("username")) ' adVarWChar
    MM_editCmd.Parameters.Append MM_editCmd.CreateParameter("param4", 202, 1, 50, Request.Form("pwd")) ' adVarWChar
    MM_editCmd.Parameters.Append MM_editCmd.CreateParameter("param5", 202, 1, 50, Request.Form("address1")) ' adVarWChar
    MM_editCmd.Parameters.Append MM_editCmd.CreateParameter("param6", 202, 1, 50, Request.Form("city")) ' adVarWChar
    MM_editCmd.Parameters.Append MM_editCmd.CreateParameter("param7", 202, 1, 50, Request.Form("state_province")) ' adVarWChar
    MM_editCmd.Parameters.Append MM_editCmd.CreateParameter("param8", 202, 1, 50, Request.Form("zip_postal")) ' adVarWChar
    MM_editCmd.Parameters.Append MM_editCmd.CreateParameter("param9", 202, 1, 50, Request.Form("country")) ' adVarWChar
    MM_editCmd.Parameters.Append MM_editCmd.CreateParameter("param10", 202, 1, 50, Request.Form("userGroup")) ' adVarWChar
    MM_editCmd.Execute
    MM_editCmd.ActiveConnection.Close

    ' append the query string to the redirect URL
    Dim MM_editRedirectUrl
    MM_editRedirectUrl = "login.asp"
    If (Request.QueryString <> "") Then
      If (InStr(1, MM_editRedirectUrl, "?", vbTextCompare) = 0) Then
        MM_editRedirectUrl = MM_editRedirectUrl & "?" & Request.QueryString
      Else
        MM_editRedirectUrl = MM_editRedirectUrl & "&" & Request.QueryString
      End If
    End If
    Response.Redirect(MM_editRedirectUrl)
  End If
End If
%><!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<title>Newland Tours: About</title>
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1" />
<link href="css/newland.css" rel="stylesheet" type="text/css" />
<script language="JavaScript" type="text/JavaScript">
<!--
function MM_findObj(n, d) { //v4.01
  var p,i,x;  if(!d) d=document; if((p=n.indexOf("?"))>0&&parent.frames.length) {
    d=parent.frames[n.substring(p+1)].document; n=n.substring(0,p);}
  if(!(x=d[n])&&d.all) x=d.all[n]; for (i=0;!x&&i<d.forms.length;i++) x=d.forms[i][n];
  for(i=0;!x&&d.layers&&i<d.layers.length;i++) x=MM_findObj(n,d.layers[i].document);
  if(!x && d.getElementById) x=d.getElementById(n); return x;
}

function MM_validateForm() { //v4.0
  var i,p,q,nm,test,num,min,max,errors='',args=MM_validateForm.arguments;
  for (i=0; i<(args.length-2); i+=3) { test=args[i+2]; val=MM_findObj(args[i]);
    if (val) { nm=val.name; if ((val=val.value)!="") {
      if (test.indexOf('isEmail')!=-1) { p=val.indexOf('@');
        if (p<1 || p==(val.length-1)) errors+='- '+nm+' must contain an e-mail address.\n';
      } else if (test!='R') { num = parseFloat(val);
        if (isNaN(val)) errors+='- '+nm+' must contain a number.\n';
        if (test.indexOf('inRange') != -1) { p=test.indexOf(':');
          min=test.substring(8,p); max=test.substring(p+1);
          if (num<min || max<num) errors+='- '+nm+' must contain a number between '+min+' and '+max+'.\n';
    } } } else if (test.charAt(0) == 'R') errors += '- '+nm+' is required.\n'; }
  } if (errors) alert('The following error(s) occurred:\n'+errors);
  document.MM_returnValue = (errors == '');
}
//-->
</script>
</head>

<body>
<a href="#top"><img src="images/spacer.gif" alt="Skip to main page content." width="1" height="1" border="0" align="left" /></a>
<table width="750" border="0" cellpadding="3" cellspacing="0">
 <tr>
  <td width="470"><img src="images/banner_left.gif" width="451" height="68"  alt="Newland Tours Banner, Left" /></td>
  <td width="280"><img src="images/banner_right.jpg" width="276" height="68" alt="Newland Tours Banner, Right" /></td>
 </tr>
 <tr>
  <td><img src="images/navbar.gif" name="navbar" width="450" height="20" border="0" alt="Navigation Bar" /></td>
  <td><img name="copyright_bar" src="images/copyright_bar.gif" width="272" height="20" border="0" alt="Copyright 2004 Newland Tours" /></td>
 </tr>
 <tr>
  <td colspan="2">    
    <h1><br />
      <a name="top" id="top"></a>Site Registration</h1>
    <p>Please take a few moments to register for the site.</p>
    <form ACTION="<%=MM_editAction%>" METHOD="POST" name="frm_register" id="frm_register">
      <table width="95%"  border="0" cellpadding="3" cellspacing="0" bgcolor="#eeeeee">
        <tr>
          <td>First Name</td>
          <td><input name="firstName" type="text" id="firstName" /></td>
        </tr>
        <tr>
          <td>Last Name</td>
          <td><input name="lastName" type="text" id="lastName" /></td>
        </tr>
        <tr>
          <td>Email Address</td>
          <td><input name="username" type="text" id="username" size="37" /></td>
        </tr>
        <tr>
          <td>Password</td>
          <td><input name="pwd" type="text" id="pwd" /></td>
        </tr>
        <tr>
          <td>Address</td>
          <td><input name="address1" type="text" id="address1" size="55" /></td>
        </tr>
        <tr>
          <td>City</td>
          <td><input name="city" type="text" id="city" /></td>
        </tr>
        <tr>
          <td>State/Province</td>
          <td><input name="state_province" type="text" id="state_province" /></td>
        </tr>
        <tr>
          <td>Zip/Postal</td>
          <td><input name="zip_postal" type="text" id="zip_postal" size="12" /></td>
        </tr>
        <tr>
          <td>Country</td>
          <td><input name="country" type="text" id="country" /></td>
        </tr>
        <tr>
          <td><input name="userGroup" type="hidden" id="userGroup" value="visitor" /></td>
          <td><input name="Submit" type="submit" id="Submit" onclick="MM_validateForm('firstName','','R','lastName','','R','username','','RisEmail','pwd','','R','address1','','R','city','','R','zip_postal','','R','country','','R');return document.MM_returnValue" value="Submit" /></td>
        </tr>
      </table>







            <input type="hidden" name="MM_insert" value="frm_register">
    </form>    </td>
 </tr>
</table>

<br />
<br />


</body>
</html>

I think the answer to your problem may be in one of the articles suggested by 'Katarey'

It could be the location of the database that is the problem. If your web is set-up for anonymous access and the IIS IUSER anonymous account doesn't have permissions on this folder then you will get this error.

Regards

Rob

Have you check to ensure ADODB.Connection is install properly?

Try this:

At a command prompt, change to the C:\Program Files\Common Files\System\Ole DB folder.
At a command prompt, type the following command:
regsvr32 sqloledb.dll
You should receive confirmation that the DLL is registered successfully

Right-click the DB folder
Sharing and Security
Security tab
Add username 'Everyone'
Check all boxes (probably Full Control)
Click Apply
Click Web Sharing
click Application Permissions
Click OK
__________________
Is this the answer? I moved my work to a new Logical Desktop. Set everything up like on old machine. Didn't work. Made changes. Did work.
Something else happen in the meantime? I don't know but this worked. (Also now working with REG)

Be a part of the DaniWeb community

We're a friendly, industry-focused community of developers, IT pros, digital marketers, and technology enthusiasts meeting, networking, learning, and sharing knowledge.