Form Error: Invalid List Index 0 - help please
Inherited this application and I have no expertise with ColdFusion at all...thanks in advance for any suggestions and help!
So, I am getting this error when I chose a person's name from the drop down menu. I verified they exist in the db. Here is the full error:
Invalid list index 0.
In function ListGetAt(list, index [, delimiters]), the value of index, 0, is not a valid as the first argument (this list has 0 elements). Valid indexes are in the range 1 through the number of elements in the list.
The error occurred in E:\~mld\Forms\inc_Form_Variables.cfm: line 67
65 : </cfquery>
66 : <cflock scope="session" timeout="10" type="Exclusive">
67 : <cfset session.RelationshipToPatient = ListGetAt(Relationship_To_Patient.PID_RELATIONSHIPLIST,ListFind(Relationship_To_Patient.PID_LIST,PatientToComplete,","),",")><!--- Respondent's relationship to patient --->
68 : </cflock>
69 : </cfif>
Resources:
Check the ColdFusion documentation to verify that you are using the correct syntax.
Search the Knowledge Base to find a solution to your problem.
Browser Mozilla/5.0 (Windows NT 6.1; WOW64) AppleWebKit/535.7 (KHTML, like Gecko) Chrome/16.0.912.75 Safari/535.7
Remote Address
Referrer http://<server Name>/~mld/Nurse/index.cfm?z=0147134&lx=1
Date/Time 24-Jan-12 07:27 AM
Stack Trace
at cfinc_Form_Variables2ecfm1668635045.runPage(E:\~mld\Forms\inc_Form_Variables.cfm:67) at cfForm2ecfm1411423523.runPage(E:\~mld\Nurse\Form.cfm:41)
The referrer above says x=1, so is there something wrong the syntax of line 67? If you need more info i'd be happy to post more. I just am so stuck and I need to get this into production and I'm a total noob. I tried putting in the debug <cfdump var="#form#"> because i used that from a previous issue but this didn't help. Is there other debug I can use? thanks!
