Sometimes, your key users are only interested in certain collections of records in a given form in Dynamics AX. There are times when you need your user to see records for all customers and other times you need to narrow it down to 'corporate' or 'small business' customers.
Dynamics AX allows the you to customize the appearance and layout of an AX form via Intellimorph but this feature doesn't allow for the automatic filtering of data. To accomplish this, the favorites feature is required to achieve this functionality and provide these users with an easy way to access their forms with these filters automatically applied.
Creating a form that opens with a pre-determined query is not hard once you know how to do it. We broke it out into two parts: Create the query and then create a shortcut to this form with that query.
Part 1 – Create and Save an Advanced Filter
- Open the form that you want to be able to open with a pre-determined query
- Click on the Advanced Query button (Ctrl+F3) . It looks like a tornado with a pencil
- Create the desired rangessorts to the tables and fields. Click on the ‘Modify…’ button on the upper right hand corner of the advanced query form
- Dynamics AX will allow the users to customize the appearance and layout of an AX form via Intellimorph but this feature will not allow for the automatic filtering of data.
- Click on the ‘Save As’ option that appears
- Enter a name to save your advanced query as (e.g., Group 20 View in Figure 2) and click 'ok'.
- Name your saved query appropriately
- Make sure that the ‘Select query’ on the advanced query form is showing the value of the save query from step 6 above. Click 'OK'
- Verify that the form shows the newly queried data. If the data is not showing up as expected, check your query again.
- Close the form.
Part 2 – Create a Favorite with a Saved Query Associated
- Find the form in the AX Navigation Bar that the saved query was just created from (in my example, it is the Customer Details).
- Right click on the form in the Nav Bar and select ‘Add to favorites’.
- Provide a name for the shortcut in the favorites in the ‘Name’ field.
- Select the appropriately saved query in the ‘Query’ field (e.g., ‘Group 20 view’ that was created in step 6 above)
- Create a favorite from a form and select the saved query that you want to associate with the favorite. Give the favorite a custom name.
- Click the 'Ok' button unless you want to select a location to create the favorite in. I will not go into detail on this step but it is a great way to organize favorites.
- When the new custom ‘Favorites’ short cut is clicked on, the target form will open with the appropriate associated query executed on that form
- When the pre-saved form is clicked, the target form will open with the query automatically being applied
If you have questions about how to open a form with a present filer in Microsoft Dynamics AX 2009, contact us.