I am simply inserting some form data in an SQL database. Every other page within the application works except for this one. I've moved my connection string around and still receive the error:
"Command text was not set for the command object."
Which is hokey, because it is ... as far as I can tell.
Basically, what I have:
*******
'Connection String is here
'Retrieve various form data
'server-side validate the data
ValidateForm = true
if len(firstname) = 0 then
ValidateForm = false
end if
'And so forth down the fields
'check to see if data might already exist
'This is where I receive the error.
strSQL = "SELECT lastname FROM db_name where lastname = '" & strlastname & "'"
Set objRS = objConn.Execute(strSQL)
If objRS.EOF Or objRS.BOF Then
'It doesn't exist
Else
'It does
End If
'Closing all my stuff down here
********************
Now, what is my server finding wrong with that?
Thanks!
"Command text was not set for the command object."
Which is hokey, because it is ... as far as I can tell.
Basically, what I have:
*******
'Connection String is here
'Retrieve various form data
'server-side validate the data
ValidateForm = true
if len(firstname) = 0 then
ValidateForm = false
end if
'And so forth down the fields
'check to see if data might already exist
'This is where I receive the error.
strSQL = "SELECT lastname FROM db_name where lastname = '" & strlastname & "'"
Set objRS = objConn.Execute(strSQL)
If objRS.EOF Or objRS.BOF Then
'It doesn't exist
Else
'It does
End If
'Closing all my stuff down here
********************
Now, what is my server finding wrong with that?
Thanks!