- see footer for list info -<
Ah OK, all is clear now :¬)

Cheers Russ


By the way, I saw on your blog you mentioned using the THIS scope in a cfc is bad - got any more info?


Snake wrote:

- see footer for list info -<
Same as you would normally, as I said.

<cfset variable = value>

Is available from any function in the CFC.

Only <cfset var name="value">

Is local to the function.

You can return variables form one funtion to another just as you return them
form the CFC to the calling template.

E.g.

<cffunction name="getname">
<cfset var myname="bob">
<cfreturn myname>
</cffunction>

<cffunction name="person">
<cfset name = getname()">
</cffunction>

--
russ

-----Original Message-----
From: [EMAIL PROTECTED]
[mailto:[EMAIL PROTECTED] On Behalf Of Damien Gallagher
Sent: 17 May 2006 14:34
To: Coldfusion Development
Subject: Re: [CF-Dev] function return

- see footer for list info -<
but how do you access the return from the innermost from the outermost?

Adrian Lynch wrote:

- see footer for list info -<
Not unless you return them in the inner most function and then again in the outer most.

Ade

-----Original Message-----
From: [EMAIL PROTECTED]
[mailto:[EMAIL PROTECTED] Behalf Of Damien Gallagher
Sent: 17 May 2006 14:12
To: Coldfusion Development
Subject: Re: [CF-Dev] function return




- see footer for list info -<
I mean something a bit different.

The original method calls totalCart - <cfset totalCart()>

I want to know if the original method can access variables (eg. an error
message) set in totalCart.

Damien


Snake wrote:



- see footer for list info -<


Any other functions in the component will have access to the arguments sent to the original method, plus any global variables you set.

i.e.

<cfset mystruct.variable = value>

Will be available to all the fucntions

<cfset var name="value">
Is only available to the function that set it.

russ

-----Original Message-----
From: [EMAIL PROTECTED]
[mailto:[EMAIL PROTECTED] On Behalf Of Damien Gallagher
Sent: 17 May 2006 13:50
To: Coldfusion Development
Subject: [CF-Dev] function return



- see footer for list info -<


When you call a function from within another function in a CFC (eg.
<cfset TotalCart()>) can you get access to the variables set in that function via the <cfreturn >?

Thanks, Damien
______>



_______________________________________________

For details on ALL mailing lists and for joining or leaving lists, go to http://list.cfdeveloper.co.uk/mailman/listinfo

--
CFDeveloper Sponsors:-


- Hosting provided by www.cfmxhosting.co.uk -<
- Forum provided by www.fusetalk.com -<
- DHTML Menus provided by www.APYCOM.com -<
- Lists hosted by www.Gradwell.com -<
- CFdeveloper is run by Russ Michaels, feel free to volunteer your help -<


_______________________________________________

For details on ALL mailing lists and for joining or leaving lists, go to
http://list.cfdeveloper.co.uk/mailman/listinfo

--
CFDeveloper Sponsors:-
- Hosting provided by www.cfmxhosting.co.uk -<
- Forum provided by www.fusetalk.com -<
- DHTML Menus provided by www.APYCOM.com -<
- Lists hosted by www.Gradwell.com -<
- CFdeveloper is run by Russ Michaels, feel free to volunteer your help -<


_______________________________________________

For details on ALL mailing lists and for joining or leaving lists, go to 
http://list.cfdeveloper.co.uk/mailman/listinfo

--
CFDeveloper Sponsors:-
- Hosting provided by www.cfmxhosting.co.uk -<
- Forum provided by www.fusetalk.com -<
- DHTML Menus provided by www.APYCOM.com -<
- Lists hosted by www.Gradwell.com -<
- CFdeveloper is run by Russ Michaels, feel free to volunteer your help -<


_______________________________________________

For details on ALL mailing lists and for joining or leaving lists, go to 
http://list.cfdeveloper.co.uk/mailman/listinfo

--
CFDeveloper Sponsors:-
- Hosting provided by www.cfmxhosting.co.uk -<
- Forum provided by www.fusetalk.com -<
- DHTML Menus provided by www.APYCOM.com -<
- Lists hosted by www.Gradwell.com -<
- CFdeveloper is run by Russ Michaels, feel free to volunteer your help -<

Reply via email to