Now and then when building a custom farcry object you might get the error ‘Element [insert object name] is undefined in a CFML structure referenced as part of an expression.’ upon accessing one of its methods by using the application scoped path eg:

createObject("component",application.types['insert type name here'].typepath)

Basically, this means that during the initialisation of the farcry application there was some sort of syntax error in the farcry object and was not able to be referenced in the application scope.

The simplest way to debug this is to make a small test file, put it into the webroot and call the object directly eg:

<cfset o = createObject("component","farcry.projects.projectname.packages.types.objectname") />
<cfdump var="#o#" />

Run the test file and it will try and create the farcry object and crash letting you know where the problem lies. All you have to do is fix the problem until you are able to run your test file without it crashing, then update the farcry application and boomshanka, all will return to a perfect state of harmony.

Post a Comment

*
*