Hi,
In this code i can get proper output only for numbers and for strings it gives error as invalid character.Pleas e help me
In this code i can get proper output only for numbers and for strings it gives error as invalid character.Pleas e help me
Code:
<%
Private Function Decrypt(ByVal encryptedstring)
Dim x, i, tmp
encryptedstring = StrReverse( encryptedstring )
For i = 1 To Len( encryptedstring )
x = Mid( encryptedstring, i, 1 )
tmp = tmp & Chr( Asc( x ) - 1 )
Next
Decrypt = tmp
strMessage=Decrypt
Response.write(Decrypt)
End Function
if (Request.Form("btnSubmit")<>"") then
strLname= Request.Form("txtlname")
call Decrypt(strLname)
End If
%>
<script language="javascript" type="text/javascript">
alert(<%=strMessage%>);
</script>
Comment