Ok, I see how your method would work, but I must ask what is the purpose of
the capability to have a CFC used as the action of a form?  What is the
proper use for this feature?

--------------
Ian Skinner
Web Programmer
BloodSource
www.BloodSource.org
Sacramento, CA


> -----Original Message-----
> From: Bryan F. Hogan [mailto:[EMAIL PROTECTED]
> Sent: Tuesday, September 23, 2003 11:44 AM
> To: [EMAIL PROTECTED]
> Subject: RE: [CFCDev] Using a CFC as the action of a form.
> 
> 
> Ian I think you shouldn't use the cfc as the action page.
> 
> 
> <cfif isDefined('FORM.Search')>
>       <cfset myReturnedQuery=myCFC.mobile(argumentCollection=FORM)>
> <cfelse>
>       <form>
> </cfif>
> -----Original Message-----
> From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED]
> Behalf Of Ian Skinner
> Sent: Tuesday, September 23, 2003 2:40 PM
> To: CF-Talk (E-mail)
> Subject: [CFCDev] Using a CFC as the action of a form.
> 
> 
> I am trying to figure out the logical flow of processing when 
> using a CFC as
> the action of a form?  Where does the application end up?  
> What scope does
> any data returned at the end of the called function with 
> <cfreturn ...> end
> up in?  Basically how does this work and how does one use this
> functionality?
> 
> The below example works in that the correct function of the method is
> called, the correct parameters are passed and the query 
> returns the correct
> data.  But now what?  What I would like is that the query is 
> returned from
> this function so that I can deal with it in the display layer of my
> application.  But, I can't figure out how to get out of the function?
> 
> Any suggestions or links to reference material would be most 
> appreciative.
> 
> Thank You.
> 
> --------------
> Ian Skinner
> Web Programmer
> BloodSource
> www.BloodSource.org
> Sacramento, CA
> 
> An Example:
> 
> Simple search form in Search.cfm
> <form action="search.cfc" method="post">
>       Mobile ID: <input type="text" name="MOBLID">
>       First Name: <input type="text" name="FName">
>       Last Name: <input type="text" name="LName">
>       <input type="hidden" name="Method" value="Mobile">
>       <input type="submit" name="submit" value="Search">
> </form>
> 
> Simple but fairly large Search query in the Mobile Method of 
> Search.cfc
>       <cffunction name="Mobile"
>                       access="remote"
>                       returntype="query"
>                       hint="Search for mobile drive contact.">
> 
>               <cfargument name="MOBLID"
>                               type="string"
>                               required="false"
>                               default=""
>                               hint="ID of mobile drive">
>               <cfargument name="LName"
>                               type="string"
>                               required="false"
>                               default=""
>                               hint="Last name of contact for mobile
> drive.">
>               <cfargument name="FName"
>                               type="string"
>                               required="false"
>                               default=""
>                               hint="First name of contact for mobile
> drive.">
> <cfdump var="#arguments#">
>                       <cfquery name="MobContact" datasource="STPR">
>                               ... SQL here ...
>                       </cfquery>
> <cfdump var="#MobContact#">
>               <cfreturn MobContact>
>       </cffunction>
> ----------------------------------------------------------
> You are subscribed to cfcdev. To unsubscribe, send an email
> to [EMAIL PROTECTED] with the word 'unsubscribe cfcdev'
> in the message of the email.
> 
> CFCDev is run by CFCZone (www.cfczone.org) and supported
> by Mindtool, Corporation (www.mindtool.com).
> 
> An archive of the CFCDev list is available at
> www.mail-archive.com/[EMAIL PROTECTED]
> 
> ----------------------------------------------------------
> You are subscribed to cfcdev. To unsubscribe, send an email
> to [EMAIL PROTECTED] with the word 'unsubscribe cfcdev' 
> in the message of the email.
> 
> CFCDev is run by CFCZone (www.cfczone.org) and supported
> by Mindtool, Corporation (www.mindtool.com).
> 
> An archive of the CFCDev list is available at 
www.mail-archive.com/[EMAIL PROTECTED]
----------------------------------------------------------
You are subscribed to cfcdev. To unsubscribe, send an email
to [EMAIL PROTECTED] with the word 'unsubscribe cfcdev' 
in the message of the email.

CFCDev is run by CFCZone (www.cfczone.org) and supported
by Mindtool, Corporation (www.mindtool.com).

An archive of the CFCDev list is available at www.mail-archive.com/[EMAIL PROTECTED]

Reply via email to