I'm trying to do it all in one request. The tech goes to close the ticket, clicks save changes, then that executes the action page. I set the variable initially in the application file, but I'm incrementing it in the action page, which would mean that at that point it's a session variable.
I have to admit, I'm still learning the best practices with respect to "how" I should be doing this. -----Original Message----- From: Mark A. Kruger - CFG [mailto:[EMAIL PROTECTED]] Sent: Tuesday, November 26, 2002 3:24 PM To: CF-Talk Subject: RE: Using a counter variable Aimee, A bit more info would be helpful. Are you trying to do this all in one request? what sort of variable is it? session? If it's a session variable then it's being reset to Zero with every request by the application.cfm page. You would need to do (with locking): <cfif NOT isdefined('session.counter')> <Cfset counter = 0> </cfif> -----Original Message----- From: Clark, Aimee [mailto:[EMAIL PROTECTED]] Sent: Tuesday, November 26, 2002 3:03 PM To: CF-Talk Subject: Using a counter variable I have an application in which I want every 7th record closed in a table to generate an email asking the user to participate in a survey. I have <cfset counter = 0> in the application.cfm file. I have <cfset counter = counter +1> in my action page right after an update that is done to the table. Then I have <cfif counter EQ 7> execute generating email then it resets the counter back to 0 However my counter is not incrementing at all. It just keep staying at 1. I'm not sure why. Can someone provide some assistance with this? Thank you, Aimee' Clark Web Developer Stinson Morrison Hecker ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~| 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 Signup for the Fusion Authority news alert and keep up with the latest news in ColdFusion and related topics. http://www.fusionauthority.com/signup.cfm