Lookup to dimensions thru a dialog

I’ve the following problem.

I’ve a dialog with some selection criteria and three fields of them are the 3 dimensions. The lookup function, if called, returns an error.

Trying to get a solution, I’ve looked in the standard classes to see if someone has declared a dimension field in a dialog. There is the LedgerTransOpening that does exactly the same as my class, but… when I do a lookup to a dimension from this class I get the same error. It seems that DimensionsLookup cannot be called from a class.

Someone can confirm to me if the same problem is present in his installation of AX2009? If it is so, it’s a standard bug, elsewhere can be a problem of my installation.

I suppose that the Dimensionslookup is written in a manner that can be called only from a form and not a class.

you mostly forgot the “what is the error message appears is?”


I have the same issue. Have you resolved it yet?

Debug assertion failed.

\Classes\DimensionsSetCaller|isCallerFieldInterCoDimension - line 14


I actually had a dialog the other day where I wanted to add a Dimension field with the posibility to do a lookup. I didn’t go by using a lookup, but Instead went by using an extended datatype to make AX automaticly create a normal lookup.

I created a ExtendedDataType which I called DimensionOne.

This one Consists of relations to DimensionOne == Dimension.num. And 0 == Dinemsions.DimensionCode, where 0 is the dimension you want to use

After that I declared it in my dialog. Se sample below

public Object dialog()
DialogRunbase dialog = super();
DimensionOne dimensionOne;

DialogField ConceptStr;

conceptStr = dialog.addFieldValue(typeid(DimensionOne),dimensionOne,“Label here”,“Some help text”);
return dialog;

This would create a field with a “pillow” in your dialog, where you can push the pillow and have a lookup.

Was this what you where after or did I missunderstand the question? (got this tip from some other place on the internet, credits not all mine)

maybe you can use EDT - DimensionCriteria, it’s worked for me

You can use EDT DimensionCriteria, it’s worked for me