![]() |
#1 |
Участник
|
dynamicsaxbi: Best Practices: Coding Guidelines
Источник: http://blogs.msdn.com/b/dynamicsaxbi...uidelines.aspx
============== Microsoft Dynamics AX 2012 Developer’s checklist when creating report solutions for Microsoft Dynamics AX 2012. The goal of this article is to promote coding guidelines that have been applied by the product development team to ensure consistency in the reporting solutions across the application. Many of the suggestions here stem from the hundreds of developer hours invested when migrating >1000 legacy production reports into Microsoft Dynamics AX 2012. Applying these strategies will help to ensure that your reports are robust and scale appropriately when deployed to production environments. DO USE…. identifierStr to specify identifiers like parameter names As explained in the MSDN article here, the identifierStr() method is used to convert an identifier into a string. Even though the article says that this method validates its argument in the AOT, the only check it seems to make is that its argument would be a valid identifier. The main benefit of using this method is that we don’t need to put the string in quotes like ‘BookId’; instead we can simply use identifierStr(BookId). This method is mainly used in the contract class, for the parm methods. For example, the parm method can be decorated with the DataMemberAttribute attribute which specifies the parameter name. This can be specified using the identifierStr() method as follows: <ul> <font size="3">DataMemberAttribute(identifierStr(DocumentDate))
__________________
Расскажите о новых и интересных блогах по Microsoft Dynamics, напишите личное сообщение администратору. |
|
|
|