Troubleshooting
Web Portal
500 Error on Submit with DropDownCheckBoxList
7 min
summary submitting a form containing a dropdowncheckboxlist can result in a 500 internal server error due to an invalid binding configuration the issue manifests as an xpath evaluation failure during model binding symptoms http response 500 internal server error endpoint post /webapi/job/current/step/0 ui behaviour error occurs when submitting the form (not during initial load) error details \<error> \<message>exception has been thrown by the target of an invocation \</message> \<details> system xml xpath xpathexception expression must evaluate to a node set \</details> \</error> affected control configuration \<dropdowncheckboxlist id="licensetype" activatebind="licensetype" label="license type" datavaluefield="licensetypeid" datatextfield="name" bindingstyle="valuelist"> \</dropdowncheckboxlist> root cause the issue is caused by an incorrect bindingstyle configuration dropdowncheckboxlist returns multiple selected values example output 1,2 bindingstyle="valuelist" does not correctly handle this format during submit during model binding, the value is processed by the xml layer (xmlvalue set), which attempts to evaluate it as part of an xpath expression this results in xpathexception expression must evaluate to a node set resolution update the control to use enumlist \<dropdowncheckboxlist id="licensetype" activatebind="licensetype" label="license type" datavaluefield="licensetypeid" datatextfield="name" bindingstyle="enumlist"> \</dropdowncheckboxlist> outcome multi select values are correctly handled as a comma separated list (e g 1,2) model binding completes successfully no xpath evaluation error form submission succeeds key takeaway for dropdowncheckboxlist controls that return multiple values, always use bindingstyle="enumlist" using valuelist in this scenario can cause binding failures and server side xpath exceptions during form submission