TheStriker
Programmer
Hello,
I am trying to test a field to see if it is valued. If it is not, then display a message box on load and redirect the user to another page but I keep getting the dreaded 'Type Mismatch' error. Here is the code:
<SCRIPT language="VBScript">
<!--
Sub CheckEmail
If (<%If (rsSiteInfo.Fields.Item("ContactEmailAddress").Value)%> ="") Then Msgbox "There is no Contact Email listed for this site. Please enter a Contact Email Address for this Site"
Response.Redirect("SiteInfoEdit.asp")
End If
End Sub
-->
</SCRIPT>
I just can't seem to satisfy this error. Any help is appreciated. Thanks
I am trying to test a field to see if it is valued. If it is not, then display a message box on load and redirect the user to another page but I keep getting the dreaded 'Type Mismatch' error. Here is the code:
<SCRIPT language="VBScript">
<!--
Sub CheckEmail
If (<%If (rsSiteInfo.Fields.Item("ContactEmailAddress").Value)%> ="") Then Msgbox "There is no Contact Email listed for this site. Please enter a Contact Email Address for this Site"
Response.Redirect("SiteInfoEdit.asp")
End If
End Sub
-->
</SCRIPT>
I just can't seem to satisfy this error. Any help is appreciated. Thanks