object Related

0
when i add new form and used data view on that page i get following error. Target page contains data view 'data view2' that needs an object.Therefore, it cannot be used here directly.Use a micro flow data source on the data view or call a micro flow that retrieve an object and then shows the page instead.
asked
1 answers
1

Sounds like you might be using this page from navigation. If so, Mendix is telling you that you can't use this page from navigation, because it needs an object to display when that page is opened, and you can't pass an object from navigation.

If you want to use your page, you can create a microflow to act as the datasource, or you can call that page from another page that has, lets say, a datagrid. Then when you select an object in the datagrid, you can use a button on the datagrid to open you dataview page (this is how the edit function of a datagrid works).

If you want to display a page from navigation, it should have a multi-object widget, like a datagrid, templategrid or listview. This way, Mendix can just retrieve a list of objects to display on that page.

Hope that helps.

answered