Error: Argument 1 of Node.appendChild is not an object. (mendix.lib.XPathSource)

In our application we have a standard dataGrid with a few search boxes. One of these searches is to search for records that are associated with a specific Account. So one of the xPath retrieves done when loading this page is one for all Account objects in the system, with no further restrictions. What a user experiences when opening this page is an everlasting loading.gif and nothing happening. When checking the browser's console, we see the following error popping up after the xPath retrieve for Account has been performed. The request and response for this request both look fine, no huge number of accounts is returned or anything. The precise error logged in the browser's console is mendix.sys.Data.get: error in error handler for xpath //Administration.Account : Argument 1 of Node.appendChild is not an object. (mendix.lib.XPathSource) http://localhost:8080/mxclientsystem/mxui/mxui.js Line 29 [obfuscated javaScript stacktrace...] Does anyone have any idea what's happening here?
2 answers

Users by default don't have any rights to view properties from the system.user entity (the Generalization that is most likely used for your Account object).

If you are filtering on any of those fields you need to either be an administrator with the right to manage users from all user roles or specific userroles (found in the project security when editing a user role).

Otherwise, you will not be able to view those values and your xpath will trigger an error. I do agree that this should be a clear error in the runtime log and not just an error in the javascript.


We ended up resolving this error by removing the DataGrid where this was happening, and creating a new one that is exactly the same as the old one.

So it seems like our model was corrupt in this case.