I'm building a form from a table. One of its fields is a enum YesNo. I can't figure out why every time I add it to the form it appears as a checkbox instead of a combobox. I want a combobox with a lookup and inside display the values "Yes" and "No". After several attempts … Continue reading AX / D365FO – Show “NoYes” Enum field as Combobox instead of Checkbox
Category: AOT
AX / D365FO – Change User options for a list of users
Users can change their own options and customizations themselves, but in some cases administrators need to change user options in bulk or for a list of users. To do this, simply enter System administration > Users Choose user and press "User options" Now you can access user setting and manage "usage data" or "Personalization"
AX / D365FO – How to add enum filter with “All values”
Sometimes customers request a specific filter in a form. The filter is based on an enum and must have All element to display all records regardless of field value. For example, a filter has 3 elements: All, Quotation, Order; although enum has only 2 elements: Quotation, Order. To achieve the result you need to add a ComboBox control in codeThe algorithm is the following:- … Continue reading AX / D365FO – How to add enum filter with “All values”
AX / D365FO – Get value from Form ComboBox
In MyForm I have a ComboBox (myComboBox) with EnumType myEnumType. I want to get its value. To get the value of the ComboBox use the selection method if(myComboBox.selection() == myEnumType::Value1) { //action }
AX / D365FO – How to get values of base enums using code in x++
static void getEnumValues(Args _args) { EnumId enumId = enumNum(LedgerDimensionType); //Put here your enum DictEnum dictEnum = new DictEnum(enumId); int numOfValues = dictEnum.values(); //This method gets the total number of enum values int counter; for(counter = 0; counter < numOfValues; counter ++) { //You can use the number of method exposed by DictEnum class Info(strFmt('%1',dictEnum.index2Value(counter))); Info(strFmt('%1',dictEnum.index2Symbol(counter))); … Continue reading AX / D365FO – How to get values of base enums using code in x++
AX / D365FO – How to Hide Enum values on a Form Lookup x++
Suppose you have a Form with an enum control ABC which contains values A,B,C. you want to hide last value of enum "C" while displaying it on the form. You have 2 ways to reach the result : Override the "Run" method in your Form (Preferred solution) public void run() { super(); YourEnumControl.delete(enum2str(ABC::C)); } Override … Continue reading AX / D365FO – How to Hide Enum values on a Form Lookup x++
AX / D365FO – FIlter an AOT Query by multiple Enum types fields
Are you creating an AOT Query and want to create a filter condition by multiple ENUM types field? In the AOT query you can do it by using a data source Range object and separate value by comma In the value field property just insert the numeric or string value of the the ENUM fields. In this example I … Continue reading AX / D365FO – FIlter an AOT Query by multiple Enum types fields
AX / D365fo – Filter by Enum value in an AOT Query
Are you creating an AOT Query and want to create a filter condition by an ENUM field? In the AOT query you can do it by using a data source Range object In the value field property just insert the numeric or string value of the the ENUM field. In this example I used the string value … Continue reading AX / D365fo – Filter by Enum value in an AOT Query
AX – D365FO – How to locate a code based on a label in AX 2012
Open development workspace and click on Tools --> Label --> Label editor Search your label by code or description anc click "Used By". Here you can find all label reference in code
AX – D365FO – Compare an XPO file with an AOT Object
To compare an XPO file with an AOT Object follow these instructions : Apen AOT, choose the object you want to compare and click Import button Choose the XPO file, click on Show Details checkbox, expand the tree, and click Compare button Choose the layout (cus, usr, etc..) you want to compare with XPO and … Continue reading AX – D365FO – Compare an XPO file with an AOT Object