Lookups Defaulting to Incorrect View in Dynamics 365 v9

Jordan Hohepa, 07 March 2019

In Dynamics 365 you can select the default view that a Lookup field will display when selecting an existing Lookup value. Along with this you are also able to select which views, if any, a User can select. In D365 v9 however there is an issue that can occur when defaulting the view, which will be described in this blog.

image

The screenshot above shows the field properties for a Lookup to a custom entity I created named ‘Test Entity’. As you can see the Default View is set at ‘Inactive Test Entities’ and the View Selector is off. The screenshot below shows what this would look like from the Users perspective, with the records being filtered to show Inactivate records.

image

The screenshot above and below highlights part of the issue, where the view selected is shown as the ‘Test Entity Lookup View’, not the ‘Inactive Test Entities’ view. Because of this if a User searches using the search box and then cancels their search, instead of defaulting back to the selected default view the dialog defaults to the ‘Test Entity Lookup View’. The screenshot below shows this as the records now being shown are the Active records instead of the Inactive records.

image

The fix for this can be seen in the screenshot below, where the default view is still the inactive view, but the View Selector is set to ‘Show Selected Views’ instead. Using this, while only selecting the default view makes sure that when cancelling the search the correct records are shown.

image