I am trying to establish an array within a structure. When I expire the 
structure programmatically (calling logout.cfm) and return to the form, 
however, the array is not initialized and new choices are printed out with 
the old (for example: if I choose "blue" the first time through and "red" 
the second time through, printing the array the second time shows both 
"blue" and "red"). Twelve is the number of possible choices for "issue". 
What am I missing? Does expiring the session not cause
[NOT IsDefined("SESSION.LetterWiz")] to evaluate as true?

Thanks!
Trey

---------- index.cfm --------

<CFIF NOT IsDefined("SESSION.LetterWiz")>
        <CFSET SESSION.LetterWiz = StructNew()>
        
        <!--- Initialize var to track the number of issues the user responds to --->
        <cfset SESSION.LetterWiz.NumberOfIssues = 0>
        
        <cfset SESSION.LetterWiz.Issue = ArrayNew(2)>
        <!--- Initialize array --->
        <cfloop index="outer" from="1" to="12">
                <cfloop index="inner" from="1" to="2">
                        <cfset SESSION.LetterWiz.Issue[outer][inner] = "">
                </cfloop>
        </cfloop>
        
</CFIF>

------------ logout.cfm -----------

<!--- expire session --->
<CFAPPLICATION NAME="test" SESSIONMANAGEMENT="yes" 
SESSIONTIMEOUT="#CreateTimeSpan(0,0,0,0)#">

______________________________________________________________________
Why Share?
  Dedicated Win 2000 Server · PIII 800 / 256 MB RAM / 40 GB HD / 20 GB MO/XFER
  Instant Activation · $99/Month · Free Setup
  http://www.pennyhost.com/redirect.cfm?adcode=coldfusionc
FAQ: http://www.thenetprofits.co.uk/coldfusion/faq
Archives: http://www.mail-archive.com/cf-talk@houseoffusion.com/
Unsubscribe: http://www.houseoffusion.com/index.cfm?sidebar=lists

Reply via email to