
October 23rd, 2003, 08:04 AM
|
|
Contributing User
|
|
Join Date: Sep 2003
Location: uk
Posts: 91
Time spent in forums: < 1 sec
Reputation Power: 6
|
|
|
type mismatch
Hi All,
i have this code in the global section of an asp page:
%>
<!-- #include file="includes/DBOpen.inc" -->
<!-- #include file="includes/ReadData.inc" -->
<%
if Request("txtUsername") <> "" then
strSQL = "SELECT Name, Password FROM Users WHERE" & _
" Name='" & request("txtUsername") & "' AND Password='" & request("txtPassword") & "'"
Set rsLogin = readData(strSQL)
this piece of code works fine. My problem is that if I have the same code layout in the Head Section on another page, I get a typemismatch error on the readdata function.
the DBOpen.inc file holds the connection object and the ReadData.inc file hold's the request to return a recordset. Even when I remove the code from the .inc files and place it directly in the page, I get the same error. has anyone else hit a similar problem.
thanks
|