RE: CFC Newbie

2010-03-22 Thread Scott Raley
Yep read those first Ben! -Original Message- From: Ben Forta [mailto:b...@forta.com] Sent: Monday, March 22, 2010 3:49 PM To: cf-talk Subject: RE: CFC Newbie These are old, but may answer the question: http://www.adobe.com/devnet/coldfusion/articles/intro_cfcs.html http

RE: CFC Newbie

2010-03-22 Thread Ben Forta
: cf-talk Subject: Re: CFC Newbie > ask and you shall be enlightened: > > http://www.bennadel.com/blog/726-ColdFusion-Application-cfc-Tutorial-And-App lication-cfc-Reference.htm While that's useful information to be sure, it doesn't address the original poster's question, w

Re: CFC Newbie

2010-03-22 Thread Dave Watts
> ask and you shall be enlightened: > > http://www.bennadel.com/blog/726-ColdFusion-Application-cfc-Tutorial-And-Application-cfc-Reference.htm While that's useful information to be sure, it doesn't address the original poster's question, which is about CFC use in general. Application.cfc is quite

Re: CFC Newbie

2010-03-22 Thread Tony Bentley
ask and you shall be enlightened: http://www.bennadel.com/blog/726-ColdFusion-Application-cfc-Tutorial-And-Application-cfc-Reference.htm ~| Want to reach the ColdFusion community with something they want? Let them know on the

Re: CFC Newbie

2010-03-22 Thread Dave Watts
> I'm trying to get out of MX non CFC world. I've now working with CF8 and > want to start converting some of my things to use CFC's. Specifically how I > can use forms to interact with CFC's to add/edit/delete data. I've read a > few tutorials from adobe about them and what I've seen on a few blo

Re: CFC Newbie Question: Encapsulation

2006-02-16 Thread Rick Root
On 2/17/06, Aaron Roberson <[EMAIL PROTECTED]> wrote: > > In my Java book it says that if a method is public, a data filed could > be assigned a value directly, BUT doing so "violates an important > principle of object-oriented programming -- that of data hiding using > encapsulation. > > However,

Re: CFC Newbie Question: Encapsulation

2006-02-16 Thread Aaron Roberson
Thanks Rick, I will surely take a look. -Aaron On 2/16/06, Rick Root <[EMAIL PROTECTED]> wrote: > Aaron Roberson wrote: > > > > I am going to keep all of these threads, print them out, and go over > > them multiple times until I begin to grasp it all. I guess I won't be > > learning CFAJAX until

Re: CFC Newbie Question: Encapsulation

2006-02-16 Thread Rick Root
Aaron Roberson wrote: > > I am going to keep all of these threads, print them out, and go over > them multiple times until I begin to grasp it all. I guess I won't be > learning CFAJAX until I get CFC's down, which is proving to be quite a > task and very lengthy process. CFCs are wonderful! If

Re: CFC Newbie Question: Encapsulation

2006-02-16 Thread Aaron Roberson
James, I am going to keep all of these threads, print them out, and go over them multiple times until I begin to grasp it all. I guess I won't be learning CFAJAX until I get CFC's down, which is proving to be quite a task and very lengthy process. Thanks again and again! -Aaron "To instantiate

Re: CFC Newbie Question: Encapsulation

2006-02-16 Thread James Holmes
No, for the moment, forget THIS. > > should be The life cycle of the instance depends on where you put it. Instantiate it in the session scope, it lasts as long as the session. Similar for the application scope. The use of THIS is to make this bit work: Inside that, the init() method re

Re: CFC Newbie Question: Encapsulation

2006-02-16 Thread Aaron Roberson
> The only use for THIS in an OO-based component is to return THIS at > the end of the constructor. That returns the entire component for use > as an instance. In Java, the constructer is for providing arguments with default values. These default values can be the ones that are automaticly assigne

Re: CFC Newbie Question: Encapsulation

2006-02-16 Thread James Holmes
The only use for THIS in an OO-based component is to return THIS at the end of the constructor. That returns the entire component for use as an instance. The properties will be in the VARIABLES scope; they can be used via getter and setter methods. This is where the ARGUMENTS scope comes in - the

Re: CFC Newbie Question: Encapsulation

2006-02-16 Thread Aaron Roberson
What about the constructor function? Shouldn't I set the properties in the THIS scope when initializing a component? Also, what is the difference between the variables scope and the arguments scope withing a method? I have seen properties defined using the cfargument tag referenced in the method u

Re: CFC Newbie Question: Encapsulation

2006-02-16 Thread James Holmes
Yes, encapsulation is an important part of OO and yes many people don't care. If you want to maintain the encapsulation, don't set thigns in the THIS scope - use a setter method to set them in the VARIABLES scope (and a getter method to get them out again): newUser = createobject("component", "

Re: CFC newbie: trying the calendar API, getting error

2005-01-25 Thread Simeon Bateman
it looks like it is specifically coded to run from the calendar folder. Try creating a calendar folder and dropping all the files in that and running it again. I dropped the folder that unzipped from the download, into my webroot. called /calendar/sample/index.cfm and the whole app came to life.

RE: CFC Newbie Discussion.

2003-06-10 Thread Raymond Camden
> > Two follow up questions. You can't directly use the var key > word in the tag; . Correct. You also can't do after any line of real code. So, your first N lines of a method will be cfargument tags, then cfset var tags, then 'real' code. So, that's why you saw me do: > Also, when

RE: CFC Newbie Discussion.

2003-06-10 Thread Ian Skinner
onent? -- Ian Skinner Web Programmer BloodSource Sacramento, CA -Original Message- From: Raymond Camden [mailto:[EMAIL PROTECTED] Sent: Tuesday, June 10, 2003 12:38 PM To: CF-Talk Subject: RE: CFC Newbie Discussion. > > So this example was meant to show how to protec

RE: CFC Newbie Discussion.

2003-06-10 Thread Raymond Camden
> > So this example was meant to show how to protect variables > inside the method? If I follow correctly, you created a > variable scoped to the 'var' scope (named "myQuery"), then > set the variable equal to the value of the Query? Does this > mean that, if I follow what you say below... >

Re: CFC Newbie Discussion.

2003-06-10 Thread Jeff
on 6/10/03 2:55 PM, Raymond Camden at [EMAIL PROTECTED] wrote: > By the way, there is one more scope you should be convered with - and > that is 'var' scoped method variables. Whenever you use a value in a > method, a value that is NOT meant to exist in the CFC whole, you should > use the var scop

RE: CFC Newbie Discussion.

2003-06-10 Thread Ian Skinner
PROTECTED] Sent: Tuesday, June 10, 2003 11:57 AM To: CF-Talk Subject: Re: CFC Newbie Discussion. You are asking all the right quesitons to learn... keep asking. :-) to keep variables protected within functions, use: to keep variables protected to the cfc and functions within the cfc, use: your own s

Re: CFC Newbie Discussion.

2003-06-10 Thread Michael Tangorre
t; <[EMAIL PROTECTED]> To: "CF-Talk" <[EMAIL PROTECTED]> Sent: Tuesday, June 10, 2003 2:49 PM Subject: RE: CFC Newbie Discussion. > Ahh, I understand now, the best practice we are talking about is protecting > the state/variables of ones objects, but using private variab

RE: CFC Newbie Discussion.

2003-06-10 Thread Raymond Camden
s/blog Yahoo IM : morpheus "My ally is the Force, and a powerful ally it is." - Yoda > -Original Message- > From: Ian Skinner [mailto:[EMAIL PROTECTED] > Sent: Tuesday, June 10, 2003 12:49 PM > To: CF-Talk > Subject: RE: CFC Newbie Discussion. > > >

RE: CFC Newbie Discussion.

2003-06-10 Thread Ian Skinner
urce Sacramento, CA -Original Message- From: Christian Cantrell [mailto:[EMAIL PROTECTED] Sent: Tuesday, June 10, 2003 11:40 AM To: CF-Talk Subject: Re: CFC Newbie Discussion. On Tuesday, June 10, 2003, at 02:20 PM, Raymond Camden wrote: > While I strongly urge folks to not use the Thi

RE: CFC Newbie Discussion.

2003-06-10 Thread Raymond Camden
ly is the Force, and a powerful ally it is." - Yoda > -Original Message- > From: Christian Cantrell [mailto:[EMAIL PROTECTED] > Sent: Tuesday, June 10, 2003 12:40 PM > To: CF-Talk > Subject: Re: CFC Newbie Discussion. > > > On Tuesday, June 10, 2003, at 02

Re: CFC Newbie Discussion.

2003-06-10 Thread Christian Cantrell
On Tuesday, June 10, 2003, at 02:20 PM, Raymond Camden wrote: > While I strongly urge folks to not use the This scope, I would _not_ > call it a bug. The This scope works _exactly_ as advertised, it's just > not the preferred way of storing data for a CFC. Raymond is correct. It is not a bug --

Re: CFC Newbie Discussion.

2003-06-10 Thread Michael Tangorre
quot;CF-Talk" <[EMAIL PROTECTED]> Sent: Tuesday, June 10, 2003 2:30 PM Subject: RE: CFC Newbie Discussion. > So what is the Preferred way to store data for a CFC? > > -- > Ian Skinner > Web Programmer > BloodSource > Sacramento, CA > > > -Origina

RE: CFC Newbie Discussion.

2003-06-10 Thread Andy Ousterhout
Here is a summary from a few previous emails: 1. Define properties(variables) as instance.X to prevent any outside view or editing of them. 2. Use "getX" methods to allow outside viewing, and "setX" methods to set the variable. 3. Define non-property variables used with each method through (c

Re: CFC Newbie Discussion.

2003-06-10 Thread jon hall
The this scope has always worked exactly as I expected, and I do prefer to use it to store data unless there is a specific reason not to. -- jon mailto:[EMAIL PROTECTED] Tuesday, June 10, 2003, 2:20:22 PM, you wrote: RC> While I strongly urge folks to not use the This scope, I would _not_ RC>

RE: CFC Newbie Discussion.

2003-06-10 Thread Ian Skinner
So what is the Preferred way to store data for a CFC? -- Ian Skinner Web Programmer BloodSource Sacramento, CA -Original Message- From: Raymond Camden [mailto:[EMAIL PROTECTED] Sent: Tuesday, June 10, 2003 11:20 AM To: CF-Talk Subject: RE: CFC Newbie Discussion. While I

RE: CFC Newbie Discussion.

2003-06-10 Thread Raymond Camden
While I strongly urge folks to not use the This scope, I would _not_ call it a bug. The This scope works _exactly_ as advertised, it's just not the preferred way of storing data for a CFC. -Raymond Camen > > Let me point out the scope bug... > > using "this" scope exposes your data members outs

RE: CFC Newbie Discussion.

2003-06-10 Thread Ian Skinner
e Sacramento, CA -Original Message- From: jon hall [mailto:[EMAIL PROTECTED] Sent: Tuesday, June 10, 2003 11:01 AM To: CF-Talk Subject: Re: CFC Newbie Discussion. This part confuses me...this scoped variables refer to the object they are contained within. It looks like you are setting th

Re: CFC Newbie Discussion.

2003-06-10 Thread Michael Tangorre
probably for a person new to CFCs, keeping them focused on CFCs and not the relations to OO would be a good start. Mike - Original Message - From: "John Quarto-vonTivadar" <[EMAIL PROTECTED]> To: "CF-Talk" <[EMAIL PROTECTED]> Sent: Tuesday, June 10, 2003

Re: CFC Newbie Discussion.

2003-06-10 Thread jon hall
This part confuses me...this scoped variables refer to the object they are contained within. It looks like you are setting them outside of a cfc. All that will do is create a structure called this, which contains x and y keys, its odd it works in the first place. I would think this should be

Re: CFC Newbie Discussion.

2003-06-10 Thread John Quarto-vonTivadar
> > Thinking about CFCs like classes in Java or C++ is natural for me, so I like > to work in that mentality.. it might be more efficient to think of CFCs like CFCs, that way you can use their features effectively, and not be disappointed or disillusioned if CFCs do things you dont expect or dont

RE: CFC Newbie Discussion.

2003-06-10 Thread Ian Skinner
Skinner Web Programmer BloodSource Sacramento, CA -Original Message- From: Michael Tangorre [mailto:[EMAIL PROTECTED] Sent: Tuesday, June 10, 2003 10:32 AM To: CF-Talk Subject: Re: CFC Newbie Discussion. Let me point out the scope bug... using "this" scope exposes your data members out

Re: CFC Newbie Discussion.

2003-06-10 Thread Michael Tangorre
not unknown... obviosuly its known :-) known as nothing! That should read the unnamed scope. Sorry If I confused matters... - Original Message - From: "Michael Tangorre" <[EMAIL PROTECTED]> To: "CF-Talk" <[EMAIL PROTECTED]> Sent: Tuesday, June 10, 2003

Re: CFC Newbie Discussion.

2003-06-10 Thread Michael Tangorre
In terms of which is the most efficient way of calling a cfcs... I like to use CreateObject(objectname,component); Thinking about CFCs like classes in Java or C++ is natural for me, so I like to work in that mentality.. like Hal Helms points out. Keep in mind though, some hosting providers limit

Re: CFC Newbie Discussion.

2003-06-10 Thread Michael Tangorre
Let me point out the scope bug... using "this" scope exposes your data members outside of the cfc. In addition, the varibales scope is not the default for not providing a scope within a CFC. There is something known as the "unknown" scope. This unknown scope allows data members to be available to

RE: CFC newbie

2002-10-18 Thread S . Isaac Dealey
> the file: > > -Original Message- > From: Michael Corbridge [mailto:mcorbridge@;macromedia.com] > Sent: Friday, October 18, 2002 10:21 AM > To: CF-Talk > Subject: RE: CFC newbie > create a CF mapping for 'com' > -Original Message- > From: Tho

RE: CFC newbie

2002-10-18 Thread Thomas Chiverton
> create a CF mapping for 'com' Ahh, great ! That was it. Friday brain fade - the sub dir I was in was mapped, so the 'com' directory I created was in the wrong place. Moving it to the actual wwwroot worked a treat. Tom Chiverton You don't have to be a mad scientist to believe in ColdFusion

RE: CFC newbie

2002-10-18 Thread Mark A. Kruger - CFG
Actually, the last object label in the dotted notation should be the name of the file: -Original Message- From: Michael Corbridge [mailto:mcorbridge@;macromedia.com] Sent: Friday, October 18, 2002 10:21 AM To: CF-Talk Subject: RE: CFC newbie create a CF mapping for 

RE: CFC newbie

2002-10-18 Thread Michael Corbridge
create a CF mapping for 'com' -Original Message- From: Thomas Chiverton [mailto:thomas.chiverton@;locavista.com] Sent: Friday, October 18, 2002 11:05 AM To: CF-Talk Subject: RE: CFC newbie > That should read "com.local.gui" sorry, mis-typed into O

RE: CFC newbie

2002-10-18 Thread Thomas Chiverton
> That should read "com.local.gui" sorry, mis-typed into Outlook, so still broken... ~| Archives: http://www.houseoffusion.com/cf_lists/index.cfm?forumid=4 Subscription: http://www.houseoffusion.com/index.cfm?sidebar=lists&body=

RE: CFC newbie question

2002-09-05 Thread Raymond Camden
oo IM : cfjedimaster "My ally is the Force, and a powerful ally it is." - Yoda > -Original Message- > From: Michael Corbridge [mailto:[EMAIL PROTECTED]] > Sent: Thursday, September 05, 2002 8:18 AM > To: CF-Talk > Subject: RE: CFC newbie question > > >

RE: CFC newbie question

2002-09-05 Thread Michael Corbridge
h... all the example code was removed from my previous email. I'll try again. cftalk1.cfm --- cftalk1.cfc          SELECT * FROM tblEmp

RE: CFC newbie question

2002-09-05 Thread Michael Corbridge
Ali, Here is a stripped down version of your cfc that works with the native 'exampleapps' datasource that is shipped with CFMX. Notes: You have set the method access='private' which means that method can only be called from another method in the component. When starting out with cfc's, I wo

RE: CFC newbie question

2002-09-04 Thread Raymond Camden
You forgot you # signs... >   to="queryemail.tblemails_to" >   from="queryemail.tblemails_from" should be >   to="#queryemail.tblemails_to#" >   from="#queryemail.tblemails_from#" Not a CFC issue - just a syntax issue.