Cold fusion errors - null null, The error occurred on line -1., and java.lang.NullPointerException
Error: null null The error occurred on line -1.
Stack Trace: java.lang.NullPointerException
I have come across these errors in the past and every single one of them is a result of a date function going awry.
One example is a client of mine using a drop down box to "create" a date. They would have a drop down for the month, a drop down for the day (31 days), then one for the year. On the action page, this line of code exists:
So whenever a user would submit an invalid date (04/31/07, 5/d/07, etc.), This line would produce a "null null" error. Cold Fusion has awesome error descriptions, so a description of "null null" leaves you scratching your head. The above error is handled by using simple error catching javascript on the form page and/or a line of server side code on the action page:
<!--- This is not a date so do something --->
</cfif>
Of course, client side error handling should have been implemented on the form page originally. Try not to forget about CFFORM and Javascript! I implemented some quick and easy client-side error handling, and this page is sitting pretty.
I have come across this error multiple times, and it has always been a date issue. If you're getting a similar error, review those dates!


http://kb.adobe.com/selfservice/viewContent.do?ext...