wow.....does your head hurt after writing all that???
it makes mine hurt....

let the <cflock> debates begin... heh

anyway....without rewriting it all (which i would really concider)

you dont have an end </cfif> for this begin
<cfif SESSION.EmailList.ffText IS NOT "">

the very last lien of what you posted should be a </cfif> (it looks like
anyway)

try that and see what happens

----- Original Message -----
From: "Mark Leder" <[EMAIL PROTECTED]>
To: "CF-Talk" <[EMAIL PROTECTED]>
Sent: Thursday, March 06, 2003 10:56 AM
Subject: RE: Cfcase


> Thanks for having a look - I'm really stumped.  It's in the area further
> down starting <cfif VARIABLES.searchCompanyShow EQ 1> ...  The error was
> thrown at that point.
> =========================
> <cfset VARIABLES.searchCompanyShow = 1>
> <cfset VARIABLES.searchStateProvinceShow = 1>
> <cfset VARIABLES.searchCountryShow = 1>
>
> <!--- Retrieve records from database --->
> <CFQUERY NAME="qEmailList" DATASOURCE=#REQUEST.dsn1#
>   CACHEDWITHIN="#CreateTimeSpan(0,0,15,0)#">
>   SELECT emailID, firstname, lastname, subscribeDate, emailaddress,
> subscriber
>   FROM e1_EmailAdr
>   WHERE subscriber = 1
>
>   <!--- If the user provided a filter string, --->
>   <!--- Also filter on fieldSelect drop down, if provided --->
> <cfif SESSION.EmailList.ffText IS NOT "">
> <cfswitch expression="#SESSION.EmailList.fieldSelect#">
> <cfcase value="All Fields">
> AND firstname <cfif #SESSION.EmailList.searchModifier# IS
> "containing">LIKE '%#SESSION.EmailList.ffText#%'
> <cfelseif #SESSION.EmailList.searchModifier# IS
> "beginning with">LIKE '#SESSION.EmailList.ffText#%'
> <cfelseif #SESSION.EmailList.searchModifier# IS "equal to">=
> '#SESSION.EmailList.ffText#'</cfif>
>
> OR lastname <cfif #SESSION.EmailList.searchModifier# IS
> "containing">LIKE '%#SESSION.EmailList.ffText#%'
> <cfelseif #SESSION.EmailList.searchModifier# IS
> "beginning with">LIKE '#SESSION.EmailList.ffText#%'
> <cfelseif #SESSION.EmailList.searchModifier# IS "equal to">=
> '#SESSION.EmailList.ffText#'</cfif>
>
> OR emailaddress <cfif #SESSION.EmailList.searchModifier# IS
> "containing">LIKE '%#SESSION.EmailList.ffText#%'
> <cfelseif #SESSION.EmailList.searchModifier# IS
> "beginning with">LIKE '#SESSION.EmailList.ffText#%'
> <cfelseif #SESSION.EmailList.searchModifier# IS "equal to">=
> '#SESSION.EmailList.ffText#'</cfif>
>
> </cfcase>
>
> <cfcase value="First Name">
> AND firstname <cfif #SESSION.EmailList.searchModifier# IS
> "containing">LIKE '%#SESSION.EmailList.ffText#%'
> <cfelseif #SESSION.EmailList.searchModifier# IS
> "beginning with">LIKE '#SESSION.EmailList.ffText#%'
> <cfelseif #SESSION.EmailList.searchModifier# IS "equal to">=
> '#SESSION.EmailList.ffText#'</cfif>
> </cfcase>
>
> <cfcase value="Last Name">
> AND lastname <cfif #SESSION.EmailList.searchModifier# IS
> "containing">LIKE '%#SESSION.EmailList.ffText#%'
> <cfelseif #SESSION.EmailList.searchModifier# IS
> "beginning with">LIKE '#SESSION.EmailList.ffText#%'
>
> <cfelseif #SESSION.EmailList.searchModifier# IS
> "equal to">= '#SESSION.EmailList.ffText#'</cfif>
> </cfcase>
>
> <cfcase value="Email address">
> AND emailaddress <cfif #SESSION.EmailList.searchModifier# IS
> "containing">LIKE '%#SESSION.EmailList.ffText#%'
> <cfelseif #SESSION.EmailList.searchModifier# IS
> "beginning with">LIKE '#SESSION.EmailList.ffText#%'
> <cfelseif #SESSION.EmailList.searchModifier# IS "equal to">=
> '#SESSION.EmailList.ffText#'</cfif>
> </cfcase>
>
> <cfif VARIABLES.searchCompanyShow EQ 1>
> <cfcase value="Company">
> AND company <cfif #SESSION.EmailList.searchModifier# IS
> "containing">LIKE '%#SESSION.EmailList.ffText#%'
> <cfelseif #SESSION.EmailList.searchModifier#
> IS "beginning with">LIKE '#SESSION.EmailList.ffText#%'
>
> <cfelseif #SESSION.EmailList.searchModifier#
> IS "equal to">= '#SESSION.EmailList.ffText#'</cfif>
> </cfcase>
> </cfif>
>
> <cfif VARIABLES.searchStateProvinceShow EQ 1>
> <cfcase value="State/Province">
> AND state <cfif #SESSION.EmailList.searchModifier# IS
> "containing">LIKE '%#SESSION.EmailList.ffText#%'
> <cfelseif #SESSION.EmailList.searchModifier# IS
> "beginning with">LIKE '#SESSION.EmailList.ffText#%'
>
> <cfelseif #SESSION.EmailList.searchModifier# IS
> "equal to">= '#SESSION.EmailList.ffText#'</cfif>
> </cfcase>
> </cfif>
>
> <cfif VARIABLES.searchCountryShow eq 1>
> <cfcase value="Country">
> AND country <cfif #SESSION.EmailList.searchModifier# IS
> "containing">LIKE '%#SESSION.EmailList.ffText#%'
> <cfelseif #SESSION.EmailList.searchModifier#
> IS "beginning with">LIKE '#SESSION.EmailList.ffText#%'
> <cfelseif #SESSION.EmailList.searchModifier# IS "equal to">=
> '#SESSION.EmailList.ffText#'</cfif>
> </cfcase>
> </cfif>
> </cfwsitch>
> ========================
>
> Thanks, Mark
>
> -----Original Message-----
> From: Ewok [mailto:[EMAIL PROTECTED]
> Sent: Thursday, March 06, 2003 10:05 AM
> To: CF-Talk
> Subject: Re: Cfcase
>
>
> > With CFSWITCH, you must have a CFDEFAULTCASE and it must be the last
> > entry in the switch.
>
> that is wrong....you do not HAVE to have a cfdefaultcase in your cfswitch
> allthough IF you do, it DOES have to be the last case in the switch
>
>
> Mark,
>
>  you can have <cfif></cfif> blocks within your case statements, yes I'd
> recheck the postioning of your open and close cfif tags the if statement
> would need to be opened AND closed before the end of that perticular case
>
> if you cant find it, just post the code here so everyone can have a look,
im
> sure its in the positioning somewhere
>
>
> ----- Original Message -----
> From: "Robertson-Ravo, Neil (RX)" <[EMAIL PROTECTED]>
> To: "CF-Talk" <[EMAIL PROTECTED]>
> Sent: Thursday, March 06, 2003 9:38 AM
> Subject: RE: Cfcase
>
>
> > oh, and no other cf tags can appear AFTER the defaultcase.
> >
> > -----Original Message-----
> > From: Robertson-Ravo, Neil (RX)
> > [mailto:[EMAIL PROTECTED]
> > Sent: 06 March 2003 14:34
> > To: CF-Talk
> > Subject: RE: Cfcase
> >
> >
> > With CFSWITCH, you must have a CFDEFAULTCASE and it must be the last
> > entry in the switch.
> >
> >
> >
> > -----Original Message-----
> > From: Mark Leder [mailto:[EMAIL PROTECTED]
> > Sent: 06 March 2003 14:35
> > To: CF-Talk
> > Subject: Cfcase
> >
> >
> > Is it possible to place CFIF statements inside a CFCASE?  When I do
> > this,
> I
> > get an error that I can't have a CFCASE after a CFDEFAULTCASE, even
> > though there are no CFDEFAULTCASE statements in the code.  Removing
> > this CFIF statement makes everything work ...
> >
> > Thanks, Mark
> >
> >
> >
> >
>
> 
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~|
Archives: http://www.houseoffusion.com/cf_lists/index.cfm?forumid=4
Subscription: 
http://www.houseoffusion.com/cf_lists/index.cfm?method=subscribe&forumid=4
FAQ: http://www.thenetprofits.co.uk/coldfusion/faq
This list and all House of Fusion resources hosted by CFHosting.com. The place for 
dependable ColdFusion Hosting.

                                Unsubscribe: 
http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=89.70.4
                                

Reply via email to