Showing posts with label intrinsic functions. Show all posts
Showing posts with label intrinsic functions. Show all posts

Friday, February 17, 2012

New AX 2012 intrinsic functions

Two new intrinsic functions were added in AX 2012. One to reference datasources of queries and another one to reference form controls:


Just want to remind the benefits of using intrinsic functions comparing to plain strings:

  • If the referenced object changes name the problem will be detected in compile time

  • The reference will be reflected as a cross-reference, making the dependencies more transparent

Monday, February 15, 2010

Messages mentioning table or field

It is the best practice to use both table or field UI name and system name in error messages. For example, the standard “The record already exists” message looks like:
Cannot create a record in Inventory model groups (InventModelGroup). Inventory model group: Std, Standard. The record already exists.
So both UI name (Inventory model groups) and system name (InventModelGroup) appear in the message.
To retrieve those names tablepname() and tablestr() functions can be used correspondingly. For the fields there are similar functions: fieldpname() and fieldstr().