Nathan I had exactly the same problem with the same example - I had to make a few changes - perhaps there is a bug in the example, I'm not sure
Kola >> -----Original Message----- >> From: [EMAIL PROTECTED] [mailto:bounce-farcry-dev- >> [EMAIL PROTECTED] On Behalf Of Nathan Mische >> Sent: 17 June 2004 00:00 >> To: FarCry Developers >> Subject: [farcry-dev] Re: Newbie Custom Rules Question >> >> I seem to recall having the same issue with a few of my custom rules. I >> think I was able to get my custom rules working by restarting the CF >> server. I know that sounds extreme (because it is ;-), and I can't say >> with %100 certainty that this is what got my custom rules working, but >> that's what I remember doing. >> >> Lazy on my part, I know. >> >> >> >-----Original Message----- >> >From: [EMAIL PROTECTED] >> >[mailto:[EMAIL PROTECTED] On Behalf >> >Of Geoff Bowers >> >Sent: Wednesday, June 16, 2004 6:43 PM >> >To: FarCry Developers >> >Subject: [farcry-dev] Re: Newbie Custom Rules Question >> > >> >Sounds like your rule object instance is not getting created. >> >Make all the properties have required="no" and see if that >> >helps for now. >> > >> >-- geoff >> >http://www.daemon.com.au/ >> > >> >Ora Martindale wrote: >> >> I've attempted to create a custom rule using the How-To guide on the >> >> subject. I copied the update code pretty closely from the How-To >> >> guides CFC (see code at bottom). I placed the rule CFC in the >> >> <application >> >> name>/packages/rules/ directory and sucessfully deployed it. >> >> >> >> When I attempt to to add the rule to a container's list it adds it >> >> okay, but when I go to the "Configure Content" tab, I get >> >the following error: >> >> >> >> "Element OBJECTID is undefined in STOBJ." >> >> >> >> It appears that arguments.objectId has a UUID value, but an empty >> >> structure gets returned to stObj when the this.getData function is >> >> called. >> >> >> >> Can anyone tell me what I'm doing wrong? >> >> >> >> Code: >> >> >> >> <cffunction access="public" name="update" output="true" >> >> hint="Edit/Update method. Shows an edit form then passes >> >structure to >> >> update method"> >> >> <cfargument name="objectID" required="Yes" type="uuid" >> >default=""> >> >> >> >> <!--- import tag library ---> >> >> <cfimport taglib="/farcry/fourq/tags/" prefix="q4"> >> >> <cfimport taglib="/farcry/farcry_core/tags/navajo/" prefix="nj"> >> >> >> >> <cfset stObj = this.getData(arguments.objectid)> >> >> >> >> <cfif isDefined("form.updateRule")> >> >> <!--- create structure for update ---> >> >> <cfscript> >> >> stObj.displayMethod = form.displayMethod; >> >> stObj.zipCode = form.zipCode; >> >> </cfscript> >> >> >> >> <!--- update object ---> >> >> <q4:contentobjectdata >> >> typename="#application.custompackagepath#.rules.ruleJhaWeather" >> >> stProperties="#stObj#" objectID="#stObj.objectID#"> >> >> >> >> <!--- display success message ---> >> >> <div align="center"><strong>Update Successful</strong></div> >> >> </cfif> >> >> >> >> <!--- get the display methods for jhaWeather type---> >> >> <nj:listTemplates typename="jhaWeather" prefix="displayJha" >> >> r_qMethods="qDisplayTypes"> >> >> >> >> <!--- show form ---> >> >> <form action="" method="POST"> >> >> <input type="hidden" name="ruleID" value="#stObj.objectID#"> >> >> <table width="100%" align="center" border="0"> >> >> >> >> <tr> >> >> <td width="20%" colspan="1" align="right"><b>Display >> >> method:</b></td> >> >> <td> >> >> <select name="displayMethod" size="1" class="field"> >> >> <!--- show available display methods ---> >> >> <cfloop query="qDisplayTypes"> >> >> <option value="#methodName#" <cfif methodName is >> >> stObj.displayMethod>selected</cfif>>#displayName#</option> >> >> </cfloop> >> >> </select> >> >> </td> >> >> </tr> >> >> <tr> >> >> <td align="right"><b>Zip Code:</b></td> >> >> <td><input type="text" name="zipCode" size="6" >> >> maxlength="5">#stObj.zipCode#</textarea></td> >> >> </tr> >> >> </table> >> >> >> >> <div align="center"><input class="normalbttnstyle" type="submit" >> >> value="Update" name="updateRule"></div> >> >> </form> >> >> </cffunction> >> >> >> >> >> >> Sincerely, >> >> >> >> Ora Martindale >> >> Jack Henry & Assoc. >> >> 913.341.3434 >> >> >> >> >> >> >> >> >> >> NOTICE: This electronic mail message and any files >> >transmitted with it are intended exclusively for the >> >individual or entity to which it is addressed. The message, >> >together with any attachment, may contain confidential and/or >> >privileged information. Any unauthorized review, use, >> >printing, saving, copying, disclosure or distribution is >> >strictly prohibited. If you have received this message in >> >error, please immediately advise the sender by reply email and >> >delete all copies. >> >> >> >> >> >> >> >> >> > >> >--- >> >You are currently subscribed to farcry-dev as: [EMAIL PROTECTED] >> >To unsubscribe send a blank email to >> >[EMAIL PROTECTED] >> >Aussie Macromedia Developers: http://lists.daemon.com.au/ >> > >> > >> >> --- >> You are currently subscribed to farcry-dev as: [EMAIL PROTECTED] >> To unsubscribe send a blank email to leave-farcry-dev- >> [EMAIL PROTECTED] >> Aussie Macromedia Developers: http://lists.daemon.com.au/ --- You are currently subscribed to farcry-dev as: [EMAIL PROTECTED] To unsubscribe send a blank email to [EMAIL PROTECTED] Aussie Macromedia Developers: http://lists.daemon.com.au/
