Hello, all. I'm working with an application where the user can add a new account, premise, and service point. Once they complete this, they have the option to go back to the beginning and do another, or go to a report page. Throughout the app there are five fields that I'm building arrays with. These are the fields that appear in the report page table. One of them is acting up and I cannot figure out why it's behaving differently than the others. It seems that it's possibly holding two values instead of one?....
Entry File:
Set the session var to the form var and set array value:
Here's where I'm building the table:
Here's the error I get:
An error occurred while evaluating the expression:
L_TEMP_SERVICE_IND=SESSION.H_TEMP_SERVICE_IND[L_LINE]
The element at position 2 in dimension 1 of object "SESSION.H_TEMP_SERVICE_IND" cannot be found. The object has elements in positions 1 through 1. Please, modify the index expression.
Here's the output when I hard code the array position to 1:
7376091053 500 N 3RD AVE 9658777414 9879549455 Y
Y
Any help or ideas would be greatly appreciated!!!! I'm at a loss right now!!!
Thanks,
Holly
Entry File:
Code:
<CFPARAM name="session.S_TEMP_SERVICE_IND" default="1">
...
<!--- Create History arrays and cycle --->
<CFSET SESSION.H_REPEAT=1>
...
<CFSET SESSION.H_TEMP_SERVICE_IND=ArrayNew(1)>
<CFSET SESSION.H_TEMP_SERVICE_IND[SESSION.H_REPEAT]="!">
Set the session var to the form var and set array value:
Code:
<CFSET SESSION.S_TEMP_SERVICE_IND=FORM.S_TEMP_SERVICE_IND>
...
<CFSET SESSION.H_TEMP_SERVICE_IND[SESSION.H_REPEAT]= SESSION.S_TEMP_SERVICE_IND>
Here's where I'm building the table:
Code:
<CFLOOP CONDITION="L_LINE LESS THAN #SESSION.H_REPEAT#">
<CFSET L_LINE=L_LINE + 1>
...
<CFSET L_TEMP_SERVICE_IND=SESSION.H_TEMP_SERVICE_IND[L_LINE]>
...
<CFIF L_TEMP_SERVICE_IND EQ "!">
<CFSET L_TEMP_SERVICE_IND=" ">
</CFIF>
...
<td width="12%" align="middle"><font size="2"> <CFOUTPUT>#L_TEMP_SERVICE_IND#</CFOUTPUT></font></td>
</tr>
</CFLOOP>
Here's the error I get:
An error occurred while evaluating the expression:
L_TEMP_SERVICE_IND=SESSION.H_TEMP_SERVICE_IND[L_LINE]
The element at position 2 in dimension 1 of object "SESSION.H_TEMP_SERVICE_IND" cannot be found. The object has elements in positions 1 through 1. Please, modify the index expression.
Here's the output when I hard code the array position to 1:
Code:
(<CFSET L_TEMP_SERVICE_IND=SESSION.H_TEMP_SERVICE_IND[1]>)
Y
Any help or ideas would be greatly appreciated!!!! I'm at a loss right now!!!
Thanks,
Holly