Like this: <cfscript> import com.cfaussie.demo;
temp = createObject("component","demo").init() ; writeDump(temp); </cfscript> Paul On Tue, Jul 19, 2011 at 10:46 AM, Steve Onnis <st...@cfcentral.com.au>wrote: > How would you even do it createObject?**** > > ** ** > > createObject(“component”, “foo”)() ?**** > > ** ** > > probably why you cant do it J**** > > ** ** > > *From:* Andrew Scott [mailto:andr...@andyscott.id.au] > *Sent:* Monday, 18 July 2011 10:08 PM > *To:* cfaussie@googlegroups.com > *Subject:* Re: [cfaussie] Re: CreateObject of itself**** > > ** ** > > Yeah you are right, I was just about to comment that back.**** > > ** ** > > So the docs are right and there is no change here, so if you do want to use > createObject() and you have the initMethod() to setup some things then the > rule you applied does apply.**** > > ** ** > > On Mon, Jul 18, 2011 at 10:06 PM, Paul Kukiel <kuki...@gmail.com> wrote:** > ** > > Well your correct in that createObject returns "this" ( ie the instance ) > but it dosn't run init(). Try put a writeOutput or dump in the init method > then running it both ways on that test page, new Test(); will display the > output but create object wont.**** > > ** ** > > I just checked my cf9 server and it's 9.01 just incase ( grr all those > updates but thats another story ).**** > > ** ** > > Paul.**** > > ** ** > > -- > You received this message because you are subscribed to the Google Groups > "cfaussie" group. > To post to this group, send email to cfaussie@googlegroups.com. > To unsubscribe from this group, send email to > cfaussie+unsubscr...@googlegroups.com. > For more options, visit this group at > http://groups.google.com/group/cfaussie?hl=en.**** > > -- > You received this message because you are subscribed to the Google Groups > "cfaussie" group. > To post to this group, send email to cfaussie@googlegroups.com. > To unsubscribe from this group, send email to > cfaussie+unsubscr...@googlegroups.com. > For more options, visit this group at > http://groups.google.com/group/cfaussie?hl=en. > -- Paul Kukiel -- You received this message because you are subscribed to the Google Groups "cfaussie" group. To post to this group, send email to cfaussie@googlegroups.com. To unsubscribe from this group, send email to cfaussie+unsubscr...@googlegroups.com. For more options, visit this group at http://groups.google.com/group/cfaussie?hl=en.