I have a strange problem
<cfset endno = #endno# - 3 >
<cfset y = Evaluate("#endno#">
<cfoutput>#y#</cfoutput>
Gives me a value of 95
But when I write
<cfset endmess = #Mid(endmess,startno + 2, #y# >
I get this error
Parameter 3 of function Mid which is now -2 must be a non-negative integer
when I put
<cfset endmess = #Mid(endmess,startno + 2, 95 >
It works just fine
Why does this happen?
<cfset endno = #endno# - 3 >
<cfset y = Evaluate("#endno#">
<cfoutput>#y#</cfoutput>
Gives me a value of 95
But when I write
<cfset endmess = #Mid(endmess,startno + 2, #y# >
I get this error
Parameter 3 of function Mid which is now -2 must be a non-negative integer
when I put
<cfset endmess = #Mid(endmess,startno + 2, 95 >
It works just fine
Why does this happen?