OK. I will try this tomorrow morning. I put it there as a simple test to make sure the mappings worked with a component. I figured that those variables would be ready-to-use once they were set. Originally, I had a data gateway object in the onRequestStart method, but I started reducing the complexity to overcome issues with the custom tag paths and mappings. At the minimum, I used my error handler component just as a test to get the paths set correctly. It appears that I simplified myself into another problem. ;^) Prior to that, I started chasing an issue with CF not following the proper hierarchy when searching custom tag paths. Adobe was kind enough to send me a hotfix for that problem. I'm glad to say that it wasn't my silliness that caused that particular problem. Thanks again for the help. mike
_____ From: Cutter (ColdFusion) [mailto:[email protected]] Sent: Wed 6/24/2009 5:11 PM To: cf-talk Subject: Re: CF8 Uses Incorrect Component Path Mark is exactly right, and you would never want to instantiate components within your Application.cfc constructor like that, as they would get re-created on every page request. You really want to put this component (your errorhandler) in the APPLICATION scope, and place it there within your onApplicationStart() method. Steve "Cutter" Blades Adobe Certified Professional Advanced Macromedia ColdFusion MX 7 Developer Co-Author of "Learning Ext JS" http://www.packtpub.com/learning-ext-js/book _____________________________ http://blog.cutterscrossing.com <http://blog.cutterscrossing.com/> On 6/24/2009 4:55 PM, Mark Mandel wrote: > I'm not 100% sure, but if you have the createObject() call straight after > the this.mappings[] code it probably won't work. > > I would expect that CF has yet to build those mappings into what it uses to > determine mapped paths yet. > > Do your createObject() call inside a index.cfm or similar, and you should > find that it works. > > Mark > > On Thu, Jun 25, 2009 at 7:43 AM, Dawson, Michael<[email protected]>wrote: > > >> Steve, I appreciate your help. >> >> I'm just not getting it to work. I've taken it back to the most-basic >> where I have a component in a Components directory. CF will still not >> find the component. >> >> I have a path at: >> >> E:\WebSites\applybeta.evansville.edu\Extensions\Components >> >> In that directory, I have the file: >> >> E:\WebSites\applybeta.evansville.edu\Extensions\Components\ErrorHandler. >> cfc >> >> In my Application.cfc, I have the following: >> >> <cfset this.mappings["/Components"] = >> "E:\WebSites\applybeta.evansville.edu\Extensions\Components"> >> <cfset errorHandler = createObject("component", >> "Components.ErrorHandler").init()> >> >> I still get "Could not find the ColdFusion Component or Interface >> Components.ErrorHandler". >> >> I'm at a total loss as to why this does not work. I wish that the CF >> error would display where (file paths) it tried to access the >> components. >> >> Thanks, >> Mike >> >> -----Original Message----- >> From: Cutter (ColdFusion) [mailto:[email protected]] >> Sent: Wednesday, June 24, 2009 4:28 PM >> To: cf-talk >> Subject: Re: CF8 Uses Incorrect Component Path >> >> >> Just do a mapping to "/edu" >> >> <cfset THIS.mapping["/edu"] = >> "E:\WebSites\applybeta.evansville.edu\Extensions\Components\edu" /> >> >> Steve "Cutter" Blades >> Adobe Certified Professional >> Advanced Macromedia ColdFusion MX 7 Developer >> >> Co-Author of "Learning Ext JS" >> http://www.packtpub.com/learning-ext-js/book >> _____________________________ >> http://blog.cutterscrossing.com <http://blog.cutterscrossing.com/> >> >> >> On 6/24/2009 4:10 PM, Dawson, Michael wrote: >> >>> Alright gentlemen, I think I have it figured out now. I do remember >>> that CF looks in custom tag paths, but that was when I was using >>> components with application.cfm and my legacy code. >>> >>> http://livedocs.adobe.com/coldfusion/6.1/htmldocs/buildi12.htm >>> >>> #4 reads "Directories specified on Custom Tag Paths page of the >>> Administrator" >>> >>> That said, I'm ready to move on to doing it the right way with >>> Application.cfc. >>> >>> I want to specify my components using a FQDN such as: >>> >>> edu.evansville.applybeta.package.component >>> >>> My components are located at: >>> >>> E:\WebSites\applybeta.evansville.edu\Extensions\Components >>> >>> I would then have the following directory structure: >>> >>> E:\WebSites\applybeta.evansville.edu\Extensions\Components\edu >>> E:\WebSites\applybeta.evansville.edu\Extensions\Components\edu\evansvi >>> ll >>> e >>> E:\WebSites\applybeta.evansville.edu\Extensions\Components\edu\evansvi >>> ll >>> e\applybeta\ >>> and so on... >>> >>> Should I: >>> * Create a "/" mapping to >>> "E:\WebSites\applybeta.evansville.edu\Extensions\Components\edu" >>> * Create a "/edu.evansville.applybeta" mapping to >>> E:\WebSites\applybeta.evansville.edu\Extensions\Components\edu\evansvi >>> ll >>> e\applybeta\ >>> >>> What is the most accepted method for mapping in this manner? >>> >>> I certainly appreciate your help with clarifying this for me. >>> >>> Thanks, >>> Mike >>> >>> -----Original Message----- >>> From: Cutter (ColdFusion) [mailto:[email protected]] >>> Sent: Wednesday, June 24, 2009 1:53 PM >>> To: cf-talk >>> Subject: Re: CF8 Uses Incorrect Component Path >>> >>> >>> Components are different from CustomTags, and your mapping is a >>> customTagPaths mapping. You'll want to use a standard cf mapping: >>> >>> this.mapping['/Components'] = 'c:\Inetpub\componentpath\'; >>> >>> Then ref that path (/Components) in your code. >>> >>> Steve "Cutter" Blades >>> Adobe Certified Professional >>> Advanced Macromedia ColdFusion MX 7 Developer >>> >>> >>> >> >> >> > > ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~| Want to reach the ColdFusion community with something they want? Let them know on the House of Fusion mailing lists Archive: http://www.houseoffusion.com/groups/cf-talk/message.cfm/messageid:323909 Subscription: http://www.houseoffusion.com/groups/cf-talk/subscribe.cfm Unsubscribe: http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=89.70.4

