TypeError: Cannot read property value of undefined
Hello, I sometimes get the below error when the app navigates to page. As it only happens sometimes it is very hard to pinpoint which widget(s) it is that causes it. Any input is appreciated. Thanks // :) Fredrik TypeError: Cannot read property 'value' of undefined at Object._setValueAttr (/widgets/widgets.js?636414149378173550:60350) at Object.r (mxui.js:5) at Object._setValueAttr (/widgets/widgets.js?636414149378173550:60039) at Object.r (mxui.js:5) at Object._setValueAttr (/widgets/widgets.js?636414149378173550:59692) at Object.r (mxui.js:5) at Object._setValueAttr (/widgets/widgets.js?636414149378173550:61588) at Object.set (mxui.js:10) at Object.attr (mxui.js:5) at Object.setDisplayValue (/widgets/widgets.js?636414149378173550:59369) error @ mxui.js:5
Scenario when running in the cloud: The browser console error you are mentioning above, should contain a reference to the widget.js file. If a linenumber is mentioned, check which widget encloses this linenumber.
Scenario when running the project locally: Set the 'bundle widgets' setting to 'true. This can be done by navigating in the Modeler to 'Project Module' > 'Settings' > 'Modeler' and tick the option 'Bundle widgets when running locally.
Once this is done, deploy your project locally. After deployment, navigate in your Mendix folder structure to the widget.js file located at: <your-project>-main\deployment\web\widgets\widgets.js and search for '_setValueAttr'. Once found, check in which widget this line occurs.
By this method you at least know which widget is causing this problem...