Hi All,
I need help in trying to figure out why a random error seems to happen. I have built a continuing education search and registration application. People will search for their workshops and then click a button to go and register/pay for the workshops. This has been live for a few months and the error below has happend a few times. It does not happen each time. It just seems to happen sporadically. I cannot figure out why most of the registrations will work and a few will not.
I am lost at why this happens every now and then. I think it is with the "TotalFees" variable.
Any suggestions would be wonderful! Thanks
ERROR:
MESSAGE The value "" cannot be converted to a number
CODE (IN THE BODY IS "ERROR OCCURS HERE ---->")
<cflock scope="session" type="readonly" timeout="5">
<CFQUERY NAME="versions" DATASOURCE="ceworkshops" DBTYPE="ODBC">
SELECT ID,Session_Number,Title,Wo
rkshopDate
,WorkshopT
ime,Member
_Earlybird
,Member_Ad
vanced_Fee
,Non_Membe
r_Earlybir
d,Non_Memb
er_Advance
d_Fee,
Member_Onsite_Fee,Non_Memb
er_Onsite_
Fee,Credit
s
FROM celisting
WHERE id IN (#session.classes#)
ORDER BY session_number
</cfquery>
</cflock>
<p>Final Schedule For <cfoutput>#attributes.fnam
e# #attributes.lname#</cfoutp
ut></p>
<cfset totalFees = "0">
<cfoutput query="versions" group="workshopdate">
<p><span class="textbold">#workshop
date#</spa
n></p>
<table>
<tr>
<td>ID</td>
<td>Title</td>
<td>Credits</td>
<td>Time</td>
<td>Fee</td>
</tr>
<cfoutput>
<tr>
<td>#session_number#</td>
<td>#title#</td>
<td>#credits#</td>
<td>#workshoptime#</td>
<cflock scope="session" type="readonly" timeout="5">
<!---shows early bird rate--->
<cfif #session.validMember# EQ "YES">
<td>#DollarFormat(member_e
arlybird)#
</td>
ERROR OCCURS HERE ----> <cfset totalFees = #totalFees# + #member_earlybird#>
<cfelse>
<td>#DollarFormat(non_memb
er_earlybi
rd)#</td>
OR ERROR OCCURS HERE ----> <cfset totalFees = #totalFees# + #non_member_earlybird#>
</cfif>
</cflock>
</tr>
</cfoutput>
</table>
</cfoutput>
<table width="100%">
<cfoutput>
<tr>
<td>Total to be Charged to Credit Card:</td>
<td>#DollarFormat(totalFee
s)#</td>
<input type="hidden" name="totalfees" value="#totalfees#">
</tr>
</cfoutput>
</table>
Start Free Trial