Adding a colour picker lookup to an AX form

Here’s a quick and easy way to add a colour picker lookup to an AX form.

I’ve seen a number of different ways to add colour picker support to an AX form, but so far, this has been the easiest.  It is not ideal, because the colour picker opens up as a dialog window, something which can’t be easily worked around without resorting to using custom ActiveX or .NET controls.

Continue reading “Adding a colour picker lookup to an AX form”

Filtered form reference group lookup

Dynamics AX 2012 introduces built-in support for resolving and looking up linked records based on reference record IDs.

When adding a reference record ID field to a form, AX will add a reference group control instead of the reference record ID, and will show a selected set of fields from the referenced table.  See the posts about tree lookups for an example.

The reference group control also does lookups into the referenced table for selecting a new value.  However, by default this lookup is not filtered and will show all records in the referenced table.  Adding filtering is quite easy to do and it follows a similar pattern as regular table lookups.

Continue reading “Filtered form reference group lookup”

How-to: Tree lookups in Dynamics AX reference group controls, part 4

This is something that keeps coming up on different projects, so I’d like to share how I usually do this.  There are some examples out there which try to describe a very generic solution which can be used in almost any case.  However, such solutions very quickly become very complex.  To keep things simple, I have tried to keep this example fairly specific but adaptable to a wide range of circumstances.  Specifically this example is using a fixed hierarchy structure with a fixed number of levels, each of which will be represented by a different table.

If you have not read the first 3 parts ( 1, 2, 3 ) of this tutorial yet, I recommend you do that first, to help with the understanding of this post, which explains how to automatically navigate to the currently selected item in the tree lookup.  This is something which is quite easy to do in a traditional lookup but requires a bit more work when dealing with trees.

Continue reading “How-to: Tree lookups in Dynamics AX reference group controls, part 4”

How-to: Tree lookups in Dynamics AX reference group controls, part 3

This is something that keeps coming up on different projects, so I’d like to share how I usually do this.  There are some examples out there which try to describe a very generic solution which can be used in almost any case.  However, such solutions very quickly become very complex.  To keep things simple, I have tried to keep this example fairly specific but adaptable to a wide range of circumstances.  Specifically this example is using a fixed hierarchy structure with a fixed number of levels, each of which will be represented by a different table.

Earlier, I have introduced the data model sitting behind the tree lookup, and last time I showed how to build the actual tree structure.

If you have not read these posts yet, I recommend you do that first, to help with the understanding of this post, which explains how to provide a more useful tree reference in the calling form.

Continue reading “How-to: Tree lookups in Dynamics AX reference group controls, part 3”

How-to: Tree lookups in Dynamics AX reference group controls, part 2

This is something that keeps coming up on different projects, so I’d like to share how I usually do this.  There are some examples out there which try to describe a very generic solution which can be used in almost any case.  However, such solutions very quickly become very complex.  To keep things simple, I have tried to keep this example fairly specific but adaptable to a wide range of circumstances.  Specifically this example is using a fixed hierarchy structure with a fixed number of levels, each of which will be represented by a different table.

Last time I introduced the data model that will sit behind the tree lookup.  This time I’ll show how to build the tree on demand to improve performance, and then how to build the actual tree lookup form.

Continue reading “How-to: Tree lookups in Dynamics AX reference group controls, part 2”