Sei sulla pagina 1di 146

Dynamics 365

Ax 7, Dynamics 365 for Operation


Dynamics 365
Cloud based application deployed on Microsoft Azure or on promise
Published in March 2016
La nouvelle solution dentreprise de Microsoft unifie ERP et CRM dans une plateforme
commune.
Dynamics 365 va plus loin, en incluant Office 365, les versions existantes dAX, NAV et CRM,
Power BI, Power Apps et la nouvelle Microsoft AppSource ainsi que laccs mobile
No multiple functional update compared with Dynamics Ax 2012 R3

Cynapsys Dynamics Ax Team 2


Dynamics 365

Cynapsys Dynamics Ax Team 3


Dynamics 365
Microsoft Dynamics AX (AX7)

Project -Madeira

Microsoft
Dynamics
CRM Online

Cynapsys Dynamics Ax Team 4


Dynamics 365 Enterprise Edition
Microsoft Dynamics AX 7 devient Microsoft Dynamics 365 Entreprise Edition for Operations
Microsoft Dynamics CRM Online devient Microsoft Dynamics 365 Enterprise Edition for Sales
Office 365, Power BI, Power Apps et SharePoint Online sont nativement intgrs.

Cynapsys Dynamics Ax Team 5


Dynamics 365 Enterprise Edition
Dynamics 365 For Sales: It is the Sales component/module of Dynamics CRM Online.
Dynamics 365 For Customer Service: It is the Customer Service/module component of Dynamics
CRM Online.
Dynamics 365 For Field Service : This is the Field Service component/Module of Dynamics CRM
Online.
Dynamics 365 For Project Service Automation: This is the Project Service component/module of
Dynamics CRM Online.
Dynamics 365 For Marketing: Microsoft recently announced that it fully will integrate Adobe
Marketing cloud with Dynamics 365 and make it the preferable marketing app for Dynamics 365.

Cynapsys Dynamics Ax Team 6


Dynamics 365 Business Edition for Financials
This is the new Financials app of Dynamics 365 (Earlier known as Project Madeira)
Primarily targeted for SMB ( Small and Meduim size Business) customers in most cases.
This does not include any of the advanced Operations functionality such as Manufacturing, E-commerce
(Retail), advanced supply chain etc.
When we say, this is targeted more for the SMB customers, we might argue whether Microsoft thinks that
SMBs do not have Operations ?
Of course some of them do and Microsoft is probably thinking those customers should chose Dynamics 365
For Operations app instead of the Financials app.

Cynapsys Dynamics Ax Team 7


Dynamics 365 for Operations
This is where most of the customers/prospects might get confused.
The name Dynamics 365 For Operations misleads a little bit.
This business app is really targeted for the enterprise customers and obviously includes full advanced
Financials functionality as well of AX 7.
With this app, customers do NOT need to buy other Financials apps such as Dynamics 365 for Financials.
Dynamics 365 for Operations has everything you need to manage your Operations, including Core Financials.
Hopefully Microsoft will rename this app to Dynamics 365 For Operations & Financials at some point :).

Cynapsys Dynamics Ax Team 8


Dynamics 365 physical components
Database Storage through Microsoft Azure SQL Database.
Environments through Virtual Machines, which allow for multiple AX systems to be deployed
Azure active directory allows to manage all of the users through a cloud based directory
Services included with Azure include
Mobile
Cloud
Batch or automatic jobs
Storage through Blobs, and you can think of blobs like folders.
Just places where pieces of code or data results can be stored.

Cynapsys Dynamics Ax Team 9


Architecture components in Ax
The server architecture deals with the data access layer and items like batch
jobs, workflow and security.
The application stack handles the various application components, such as the
application platform and foundation models.
Virtual architecture is not a component of the Dynamics AX architecture.
Lifecycle services and Microsoft Azure are components of the Cloud
Architecture. They work together to deploy virtual machines containing
instances of Dynamics AX.

Cynapsys Dynamics Ax Team 10


AX 7 Conceptual architecture
Devices (Cross platform: Windows, Android, iOS, OS X)

Lifecycle Services
Office (Office 365, Sharepoint, Skype etc)

Trial & signup

Visual Studio developer experience


Partner Apps
Provisioning
AX 7 ERP application
(based on the AX 2012 R3 CU9 App) Deployment
Diagnostics, Telemetry &
Monitoring

Configuration
Implementation
AX 7 Platform Experience
Upgrade Experience
Analytics &
Client Server Integration Support Experience
Reporting

Microsoft Platform (including Azure/AAD/Commerce/Marketplaces)


Cynapsys Dynamics Ax Team 11
Cloud Architecture
Lifecycle
Services

Cloud
Architecture

Shared Dynamics
services AX

Cynapsys Dynamics Ax Team 12


Azure Components

Azure
Azure Active Directory
SQL Azure
AOS Service

Cynapsys Dynamics Ax Team 13


Integration: Overview
Azure App Services
(BizTalk)
Custom Apps Application Lifecycle (LCS) data management tasks e.g.
& integrations - Data migration for initial system load
- Move data between AX instances (Test Prod)
- Master data synchronization etc.

Single record or
batched records Asynchronous high volume interface

SOAP REST OData Data Import/Export Framework (DIXF)


(HTTPS/XML) (HTTPS/JSON) (HTTPS/JSON/XML)

File Upload Transform Data Staging Validation Mapping

Data Entity (simplified projection of schema)


X++ Class
Relational Aggregate
X++ Class Table(s)
Query Query
Application Server (AOS)

Azure SQL Database


RowStore & ColumnStore
Functional update
Cost Management
Retail
Financial Management
Warehouse Management

Cynapsys Dynamics Ax Team 15


Technical update
Developement environnement is Visual Studio 2015.
Web-based client on IIS 7, no need to bring the entire AOS, Now with AX 7, All AOS Configurations are stored
in IIS
Pas d interprteur X++ et pas de fichier p-code.
Toute la compilation est avec le framework .Net CIL (Compile Intermidiate Language).
Business connector nest plus support.
Enterprise portal nest plus support.
Tous est sur une VM machine virtuelle ( si jai cinq dveloppeur, je dois dployer cinq machines.
In new AX architecture, AOS windows service has been removed
Added a telemetry system called Kusto Query that can track and report individual tenant performance and
deliver proactive warnings by monitoring conditions across the larger set of customer tenants.
Extensive use of Dashboards, composable workloads and task replays.
Introduced Workspaces to facilitate role-based tasks and business processes.
Workspaces as single windows designed to guide users on what's most important right now.
workspaces reduce keystrokes and make navigation more intuitive.
Commands and menus are also context-sensitive which reduces training and aids
productivity. Cynapsys Dynamics Ax Team 16
Diffrences entre Ax R3 and Ax 7

Cynapsys Dynamics Ax Team 17


Elements of AX not supported in Dynamics 365
Enterprise Portal developement :
Web menu items
Data set
Visual studio projet
Shared and private Project
Parts
Info parts
Form parts
Cues
Cues groups
Report libraries
Security process cycle

Cynapsys Dynamics Ax Team 18


Dynamics 365 Developement
Ax 7
What is a Dynamics AX model?

A collection of elements (metadata/source files) that represent a distributable software


solution.
A visual studio project is not the same thing as a model. A project belongs to a model, and a model may
have several different projects.
Models are a logical grouping of elements that relate to some specific solution.
A model is not used to deploy customizations to a production environment, this would be a package.
Metadata for models is stored locally in an xml file called Descriptor.XML.

Cynapsys Dynamics Ax Team 20


Packages

Packages contain 1 or more models

Packages can reference other packages

Builds can be performed against 1 package or all packages

Cynapsys Dynamics Ax Team 21


Package
A package is essentially a DLL file that contains one or more models.
Its a deployement unit.
Packages could reference other packages in order to use elements from the models within the referenced
package.
Package is equivalent to Ax 2012 model store.
a package corresponds to its own mini-model store, with its own layers and models.
Translates to a .NET assembly, meaning it's a unit of compilation (DLL).
Split in smaller packages means smaller and faster compiles and smaller and faster deployments.
References are not transitive and usually the package at a "higher" layer needs to reference some of the lower
layer packages as well.
Contient les DLL, fichiers XML et les ressources.

Cynapsys Dynamics Ax Team 22


Visual Studio Solution
Solution Visual studio peut contenir plusieurs model de diffrents packages.
Solution est un groupement dobjets permettant de grer le dveloppement
des objets.

Cynapsys Dynamics Ax Team 23


Solution package Model projet lment

Cynapsys Dynamics Ax Team 24


Layers
Relevant (pertinent) for over-layering development approach
Customizations in separate layers
Irrelevant when using extensions
Models over-layer each other
Layer est une propriet dun model pour rsoudre le conflit entre model

Cynapsys Dynamics Ax Team 25


Model Driven Architecture

Layers
Cynapsys Dynamics Ax Team 26
What does an elements XML file contain?
An elements XML file contains both metadata and source code.

Cynapsys Dynamics Ax Team 27


Models
Created in Visual Studio
Over-layer each other
Metadata stored in Descriptor.XML file
Primary system models
Application Platform
Application Foundation
Application Suite

Cynapsys Dynamics Ax Team 28


Models

Primary Application Platform


system Application foundation
Application Suite
models

Cynapsys Dynamics Ax Team 29


Model and assemblies in D365

Cynapsys Dynamics Ax Team 30


Application Stack

Fleet Management Application Suite

Application Foundation

Global Address
Organization Model Number Sequence Source Documents
Book

Application Platform

Runtime & Data Workflow & Client &


SSRS Reporting
Access Services Presentation

Cynapsys Dynamics Ax Team 31


Architectures

Cynapsys Dynamics Ax Team 32


Model stores are represented as a set of
folders and XML artifacts.
The model store is represented as folders, organized by model. XML files
represent different elements within that model and store the metadata and
source code for that element.
AOT artefacts such as tables classes and forms are xml files,

Cynapsys Dynamics Ax Team 33


Dynamics 365 Packages
ApplicationCommon
ApplicationFoundation
ApplicationFoundationFormAdaptor
ApplicationPlateform
ApplicationPlateformFormAdaptor
ApplicationSuite
ApplicationSuiteFormAdaptor
ApplicationWorkspace
ApplicationWorkspaceFormAdaptor
Budget
Calendar
CalendarFormAdaptor

Cynapsys Dynamics Ax Team 34


Dynamics 365 Packages

CaseManagement
CaseManagementFormAdaptor
contactPerson
ContactPersonFormAdaptor
CostAccounting
CostAccountingAX
CostAccountingAXFormAdaptor
CostAccountingFormAdaptor
Currency
CurrencyFormAdaptor
CustomerAcceptanceTests
DataExpansionTool

Cynapsys Dynamics Ax Team 35


Dynamics 365 packages

DataImpExpApplication
DataSharing
DataStack
DemoDatasuite
Dimensions
DimensionFormAdaptor
Directory
DirectoryFormAdaptor
ElectronicReporting
Expense
ExpenseFormAdaptor
FinancialReporting

Cynapsys Dynamics Ax Team 36


Dynamics 365 Packages

financialReportingAdaptor
FiscalBooks
FiscalBooksFormAdaptor
GeneralLedger
GeneralLedgerFormAdaptor
InstallationRecords
Ledger
LedgerFormAdaptor
Measurement
MeasurementFormAdaptor

Cynapsys Dynamics Ax Team 37


Dynamics 365 Packages
Personnel
PersonnelCore
PersonnelCoreFormAdaptor
Plugins
Policy
policyFormAdaptor
Project
ProjectMobile
PublicSector
publicSectorFormAdaptor
SourceDocumentation
SourceDocumentationFormAdaptor
sourceDocumentationTypes
StaticMetedata
Cynapsys Dynamics Ax Team 38
Dynamics 365 Packages
Subledger
SubledgerFormAdaptor
SystemHealth
Tax
TaxEngine
TaxFormAdaptor
TestEssentials
Tutorial
UnitOfMesure
UnitOfMesureFormAdaptor

Cynapsys Dynamics Ax Team 39


Models

Cynapsys Dynamics Ax Team 40


Model store et les packages

Cynapsys Dynamics Ax Team 41


Dynamics 365 Packages and models

Cynapsys Dynamics Ax Team 42


Extension et overlayring
Extension
Extend metadata by adding a field to a table or adding a control to a
form, and extend business logic by defining event handlers.
More flexible
Leave the system behavior and attach the new behavior to it.
Les modification sont stock dans un assembly spar ce qui augmente
la performance de la mise niveau ( upgrade).
Overlayring
Modify existing code by changing system behavior.
Customize in a higher layer
Seems simple but it will cost you on upgrade, hotfixes, maintaining
code and merging code.
Manipulation in Visual studio
Customize = overlayring
Create Extension = extension in the same projet
Create Extension in new project = extension in a separated projet
Cynapsys Dynamics Ax Team 43
Extension

Cynapsys Dynamics Ax Team 44


Avantages de lextension
By creating extension elements, all of the customizations and code are stored in
a separate assembly.
and only contains the code added or changed in the extension.
Since this code resides in a separate assembly,
it improves the performance of building and testing.
This approach is also ideal when it comes to upgrading as it eliminates metadata
conflicts.

Cynapsys Dynamics Ax Team 45


Inconvnient de lOverlayring
OverLayring means if you do change/customize any element in upper layer, it
will override its definition, in lower layer.
Modify a SYS ( bottom layer ) element from the USR layer (higher lay) means, overriding
it in the higher layer (create the same element with the new definition)
But every layer have its patch layer above, and in every upgrade added in the patch layer
conflict will be introduced.
Old solution for customization used in Ax version.

Cynapsys Dynamics Ax Team 46


Mthode dExtension

Extension

Plugins : class factory


Meta-data extension pattern that
Class extension. eventing
(table, forms ). implement a particular
version of the class.

Cynapsys Dynamics Ax Team 47


Extension

Cynapsys Dynamics Ax Team 48


Class dExtension
The class must be postfixed with "_extension".
The class must be static.
The extension methods must be static.
The type of the first parameter determines which type is extended.
Exemple dextension DirPersonName
[ExtensionOf(tableStr(DirPersonName))]
static class MyDirPersonName_Extension
{
static public PersonName fullName(DirPersonName _person)
{
return strFmt('%1 %2 %3', _person.FirstName, _person.MiddleName, _person.LastName);
}
}

Cynapsys Dynamics Ax Team 49


Exemple dextension salesTable

Cynapsys Dynamics Ax Team 50


Label files

Cynapsys Dynamics Ax Team 51


Tables

Cynapsys Dynamics Ax Team 52


Table Indexes

Cynapsys Dynamics Ax Team 53


Table Relations

Cynapsys Dynamics Ax Team 54


Data Model

Cynapsys Dynamics Ax Team 55


Views

Cynapsys Dynamics Ax Team 56


Maps

Cynapsys Dynamics Ax Team 57


Table collections

Cynapsys Dynamics Ax Team 58


Queries

Cynapsys Dynamics Ax Team 59


Data entities

Cynapsys Dynamics Ax Team 60


Composite data entities

Cynapsys Dynamics Ax Team 61


Aggregate data entities

Cynapsys Dynamics Ax Team 62


Module Review

Business rules allow creation of client-side logic with no programming


required.
Rules can be created to run client side only or to run server side
Rules are best used when you have simple business requirements
that can be met without getting over-complicated trying to fit within
capabilities of rules

Cynapsys Dynamics Ax Team 63


Cynapsys Dynamics Ax Team 64
Application Explorer

Filtrer lapplication explorer par :

Modified Extension
Type Name Model
Date Point

Cynapsys Dynamics Ax Team 65


Classes

Classes contain Variables


Variables
Methods

Class

Methods constructor

Cynapsys Dynamics Ax Team 66


Application Explorer

Cynapsys Dynamics Ax Team 67


User interface
Navigation, Form pattern, sub-pattern, menu items,
tiles, workspace, ListPage, Master page
AX7: Security Authentication for UI (SAML 2.0)

enter your Azure Active Directory user and password


1. Sign-in via AAD (can be multi-factor AuthN) 2. AAD redirects to AX 7 3. AX 7 start page displayed

Cynapsys Dynamics Ax Team 69


Navigation

Cynapsys Dynamics Ax Team 70


Navigation

Cynapsys Dynamics Ax Team 71


Navigation in mobile

Cynapsys Dynamics Ax Team 72


Role center

Cynapsys Dynamics Ax Team 73


Dashboard

Cynapsys Dynamics Ax Team 74


Dashboard : Navigation seach

Cynapsys Dynamics Ax Team 75


Dashboard : PowerBI

Cynapsys Dynamics Ax Team 76


Workspace
client is now run in a web browser
The Workspace is focused on the tasks required for the users job.
They should be able to view and act on what they need from this single window.
No dependency on Sharepoint
Close connection to PowerBI
Workspaces are designed as starting point for the daily work in Dynamics AX.

Cynapsys Dynamics Ax Team 77


Workspace

1.Buttons to add new information.


2.Tiles to surface critical tasks and to-dos.
3.List pages with commonly accessed records and buttons.
4.Charts and PowerBI reports to review historical trends.
5.Links to favorite forms.
Cynapsys Dynamics Ax Team 78
Workspace

Cynapsys Dynamics Ax Team 79


Workspace

Cynapsys Dynamics Ax Team 80


Workspace : Navigation Pane

Cynapsys Dynamics Ax Team 81


ListPage

Cynapsys Dynamics Ax Team 82


Master dtails
Details form for master data

Cynapsys Dynamics Ax Team 83


Transaction Details
Details form for transactional data

Cynapsys Dynamics Ax Team 84


Simple List

Cynapsys Dynamics Ax Team 85


Simple List and details

Cynapsys Dynamics Ax Team 86


Cynapsys Dynamics Ax Team 87
Cynapsys Dynamics Ax Team 88
Dialog basic

Cynapsys Dynamics Ax Team 89


Dialog w/tabs

Cynapsys Dynamics Ax Team 90


Dialog w/FastTabs

Cynapsys Dynamics Ax Team 91


Dialog w/double tabs

Cynapsys Dynamics Ax Team 92


Dialog (read only)

Cynapsys Dynamics Ax Team 93


Task

Cynapsys Dynamics Ax Team 94


Form Patterns

In Visual Studio
Dynamics 365 menu Addins Form Statistics

Cynapsys Dynamics Ax Team 95


Form pattern What its used for
Details master (two variants) A form that displays the details of a complex entity

Details transaction A form that displays the details of a complex transaction entity and its lines (for example, and order and its lines)

Dialog (six variants) A form that is used as a dialog to gather a set of information

Drop Dialog (two variants) A form that is used as a drop dialog to gather a small set of information to provide context for an action

FactBox(two variants) FactBox that displays information about a related record or set of records

ListPage List Page


lookup (three variants) A form that is used as a lookup

Simple details (four variants) A form that is focused on a single record

Simple List A form that displays details for a simple entity as a grid that has fewer than 10 fields per record

Simple List & details (three variants) A form that displays information about an entity of medium complexity

Table of content A form that displays setup information or loosely related information sets
Task (two variants) A legacy form pattern that is used to display master or transaction entities

wizard A form that displays a set of tab pages to the user to gather information in a predetermined order

Operational Workspace A form that is used to display an overview of an activity and is meant to be a primary means of navigation

Workspace Panorama Sections (three


A form that is used to show content
Cynapsys for a panorama
Dynamics Ax Team section (via a Form Part Control) in the Operational Workspace
96
variants)
Form Patterns
Details master List page
Details master w/standard tabs Lookup basic
Details transation Lookup w/preview
Dialog advanced selection Lookup w/Tabs
Dialog basic Simple details w/fast tabs
Dialog double task Simple details w/panorama
Dialog fasttabs Simple details w/toolbar and fields
Dialog read only Simple list
Dialog tabs Simple list and details listgrid
Drop dialog Simple list and details tabular grid
Drop dialog read only Simple list and details tree
Form part factbox card Table of content
Form part factobox grid Task double
Form part section list Task single
Form part section listdouble wizard
Hub part chart
Hub part grid

Cynapsys Dynamics Ax Team 97


Form Patterns

Cynapsys Dynamics Ax Team 98


Form control
Action pane Drop dialog button
Availability view Expression builder
Button File upload
Button group Filter display
Calendar Form part
Calendar table Grid
Chart Group
Check box GUID
Clock card Hierarchical grid
Clor picker Hierarchy viewer
Combo box HTML Editor
Command button HTML Viewer
Date Imager
Date time Int64
Dimention entry Integer
Document attachement List box
List view

Cynapsys Dynamics Ax Team 99


Sub-Pattern

Cynapsys Dynamics Ax Team 100


Styles

Cynapsys Dynamics Ax Team 101


Template

Cynapsys Dynamics Ax Team 102


Types de bouton

Button

Menu button

Menu item button

Command button

Drop dialog button

Cynapsys Dynamics Ax Team 103


Proprits de bouton

Cynapsys Dynamics Ax Team 104


Types de donnes dans
Dynamics 365
Tables,
Data Entity Categories

Parameter
Reference
Master
Document
Transaction

Cynapsys Dynamics Ax Team 106


Type of Data
Parameter - Functional or behavioral parameters.
Required to set up a deployment or a module for a specific build or customer.
Can include data that is specific to an industry or business. The data can also apply to broader set of customers.
Tables that contain only one record, where the columns are values for settings. Examples of such tables exist for
Account payable (AP), General ledger (GL), client performance options, workflows, and so on.
Reference - Simple reference data, of small quantity, that is required to operate a business process.
Data that is specific to an industry or a business process.
Examples include units, dimensions, and tax codes.
Master - Data assets of the business. Generally, these are the nouns of the business, which typically
fall into categories such as people, places, and concepts.
Complex reference data, of large quantity. Examples include customers, vendors, and projects.
Document
Worksheet data that is converted into transactions later.
Documents that have complex structures, such a several line items for each header record. Examples include sales
orders, purchase orders, open balances, and journals.
The operational data of the business.
Transaction
The operational transaction data of the business.
Posted transactions. These are non-idempotent items such as posted invoiced and balances. Typically, these
items are excluded during a full dataset copy.
Examples include pending invoices. Cynapsys Dynamics Ax Team 107
Type of Data

Cynapsys Dynamics Ax Team 108


MB6-890 Exam
Questions
How can you visualize elements organized
by model (Model View)?

By right-clicking on the AOT node in the Application Explorer and selecting model
view
To see elements organized by model view, you must open the application
explorer and right-click the AOT node to switch between Classic view and Model
view.

Cynapsys Dynamics Ax Team 110


Ressources in Ax
Resources do not store textual information, but graphical or visual
information.
System memory and CPU can be considered computer resources, however,
resources in Dynamics AX are entirely different.
Label files only store information about labels.
Resources are pictures or icons that are stored in the system. For example, a
product image or a logo is considered a resource in Dynamics AX.
Resources are not stored in table

Cynapsys Dynamics Ax Team 111


Labels :Which scenario best describes
when labels should be created and used?

Label files may have multiple values, which represent the same text or
value in different languages.
For all properties and variables that are text strings visible to application
users.
They provide clarity, consistency and are fully searchable. In addition,
they support direct translation into other configured languages and can
be updated in one spot.

Cynapsys Dynamics Ax Team 112


How are base enumerations represented and
stored in the database?
As a literal string value
As a numerical value
The literal string value is defined in Dynamics AX. This is what end users will see
on forms and reports. However, the literal value is not stored in the database.
A different numerical value represents a different choice or literal value for
the enumeration. This relationship is defined in Dynamics AX. The value that
is stored in the database is the numerical value for the enumeration.

Cynapsys Dynamics Ax Team 113


Which of the following are benefits of
using EDTs ?

Reusability
Code is easier to read
Inherited properties and consistency

Cynapsys Dynamics Ax Team 114


The order of the columns in an index is
not important.

This statement is false.


The order of the columns in an index is very important.
The columns in an index should be organized from the most granular
to least granular.

Cynapsys Dynamics Ax Team 115


Valid types of table indexes used in Dynamics
AX
Primary Index
Partial Index
Clustered Index
Non-clustered Index
A Primary Index is used to provide a unique key to each record in a table. The
allow duplicates property must be set to No to prevent duplicate key values
A partial index is not used in Dynamics AX.
A Clustered index is used to determine how data is organized in a table.
A Non-Clustered Index is used to quickly reference data found in the clustered
index.
Cynapsys Dynamics Ax Team 116
Delete Action

When the value Restricted is set for the On Delete property, records can
only be deleted from the table when there is nothing that relates to it in
another table.
The Cascade property value specifies to delete the selected row in the
table, along with all data in relating tables
The Cascade + Restricted property value will perform a cascade delete,
meaning the data will be deleted despite records existing in relating tables.
However, a warning will appear first providing the user with the option to
confirm or deny the cascade delete action.
When the property value is set to None, it allows the row in the table to be
deleted, but does nothing to records in related tables.

Cynapsys Dynamics Ax Team 117


The default first literal value or option in
an enumeration is internally represented by
the number 1.
False: This statement is false.
The first literal value in a base enumeration is represented by the number
0 by default.
The second literal or option in the enumeration is represented by a 1, and
so on.
These numerical values can also be changed by a developer, however.

Cynapsys Dynamics Ax Team 118


Table relation best practice
Defining the relation on the table holding the primary key is a best practice.
Normal relation
Field fixed relation
Related field fixed relation
Foreign key

Cynapsys Dynamics Ax Team 119


Which two of the following types of
relations can only be created on numeric
fields?
Field fixed relation
Related field fixed relation
A normal relation can be created on any field type.
A field fixed relation can only be created on a numeric field. A numerical
value must be entered for the Value property of the selected field to act
as a filter.
A related field fixed relation can also only be created on a numeric field.
A numerical value must be entered for the Value property of the selected
field to act as a filter.
A Foreign Key Relation specifies correspondence between a foreign key
field in the present table and the primary key field in another parent table.
It is not restricted to numerical field types.

Cynapsys Dynamics Ax Team 120


Form patterns are applied to a forms
design node, while form sub-patterns are
applied to certain form controls.
Form patterns are applied on the forms design node and sub-
patterns are applied to specific controls within the form.
The form pattern impacts the layout of the entire form, while the sub-
pattern impacts a specific part, such as a tab page or group control.

Cynapsys Dynamics Ax Team 121


About Resources

Icons

Visual
Pictures
representations

Resources

Cynapsys Dynamics Ax Team 122


Best practice in
Dynamics AX
Form-Queries-Tables-Table Fields-Table group-Table Relation-
Code and Classes- EDT-Base Enum

Cynapsys Dynamics Ax Team 123


Form Best Practices
Name the form to coincide with the main data source table
Use the Auto and Default properties for sizing
Use the form statistics add-in for guidance
(submenu on the Dynamics AX menu, Add-ins submenu on the
shortcut menu in the element designer)
provides a summary of the pattern usage for forms.
Try to cover all controls with the applied pattern
Avoid placing code on forms - Codes should typically be placed in a
class or table.

Cynapsys Dynamics Ax Team 124


Best practices for queries

Best practice to use a query when the nature of data being selected is not known
at runtime.
Best practice to create queries by adding them to your projects and editing them
with the element designer instead of building them in code.
Best practice to use them as the underlying data source for forms and reports.

Cynapsys Dynamics Ax Team 125


Table best practice (naming convention)
Include prefixing the name with the module name that the table relates to.
For example, cust vend or invent should be prefixed on the table name that relates to
those modules.
Prefix it with a logical description of the table's contents.
For example, cust collection letter trends.
For temporary tables, we prefix them with TMP.
Post fix the table name with the type of contents.
For example, a table that contains transactions might end in the world trans or a table
that contains line level details might end in the word line, like sales line.
The primary tables for the major business areas are post fixed with the word
table itself.
For example, cust table is the master table for customers.
Cynapsys Dynamics Ax Team 126
Table best practice (table group)
The table group property is a mandatory property set to group for tables that
contain grouping and categorization information.
Deleting records from a group table can sometimes result in an unstable
situation.
Enable confirm deletion for this situation.
Typical examples of group tables from the standard application are custGroup
and vendGroup tables

Cynapsys Dynamics Ax Team 127


Table best practice (Title field)
Title field one should be a key field for the records in the table.
Title field two should be a descriptive field for the records in the table.
For example, the table invent item group table, the title field one property is item group ID,
and the title field two property is set to name.

Cynapsys Dynamics Ax Team 128


Table Field best practice
They add time to the application fetch and they add time to the database fetch.
They also inhibit array fetching and cannot be used in we're expressions.
Consider using text fields with a specific number of characteristics instead of memo fields.
For example, use the addressing extended data type for the addressing fields.
Or use the item free text extended data type for the item description on order lines.

Cynapsys Dynamics Ax Team 129


Table relation best practice
When using table relations, the name of the relation should contain the name of the table it relates to.
relation should be defined in the table holding the foreign key.
This is typically the child table. The validate property on the relation must be set to yes, which is the default
value for a foreign key relation
Configuration key, the key that is specified for the field in a relation must be the same key or in the same tree
of keys as the one used in the related field.
Navigational relationships do not enforce integrity constraints but they're used for navigational purposes.
For example, when a form is opened within another form. The validate property on these should be set to no.

Cynapsys Dynamics Ax Team 130


Table Field Group Best practice
Field groups organize related fields and related data.
It's a best practice to use field groups when designing forms as well, because when additional fields are
added to the field group on a table, it will dynamically update the form with the new field that was added to
the field group.
You should place at least two fields in the auto report field group for each table except for parameter tables.
The fields used for the title field one and title field two properties are often candidates for this field group.
If you do not put anything into the auto lookup field group, the auto lookup form will contain the fields used
in the title field one and title field two properties plus the field in the first unique index.

Cynapsys Dynamics Ax Team 131


Classes and coding best practice
consider when using classes include to have only one successful return point in the code which is typically the last
statement with the exception of switch cases or when checking for start conditions.
We should keep our building blocks or methods small and clear.
A method should do a single well-defined job and, therefore, should be easy to name.
You should also put comments in your code which tells others what the code is supposed to do and what the
parameters are used for.
Do not assign values to or manipulate actual parameters that are supplied by value.
You should always be able to trust that the value of such parameter is the one initially supplied. You should treat
such parameters as constants as well.
clean up your code, delete any unused variables, methods, or classes, to keep everything precise and correct.

Cynapsys Dynamics Ax Team 132


Base enums best practice
Always let the constant field in the table to be enumerator
Never use numeric constant in the table field instead of enums
Never use other constants (such as other enum types) instead of enums (Booleans are compatible with all
enums).
Do not make Boolean tests on enum fields, except where the 0/false value is clearly the one with the false
outcome.
Never use relationnel operators on enums
Never compare or assign to enums of different types

Cynapsys Dynamics Ax Team 133


EDT best Practice
Use labels for all user interface text
The help text should not be the same as the label
Leave the display length and style as Auto when possible
Specify the enum type for all enums

Cynapsys Dynamics Ax Team 134


Best practice avec Visual Studio
Microsoft.Dynamics.AX.Framework.BestPracticeFramework.UIRules
Microsoft.Dynamics.AX.Framework.CodeStyleRules
Microsoft.Dynamics.AX.Framework.DataAccessRules
Microsoft.Dynamics.AX.Framework.DataEntityRules
Microsoft.Dynamics.AX.Framework.DeprectatedElementsRules
Microsoft.Dynamics.AX.Framework.MaintabilityRules
Microsoft.Dynamics.AX.Framework.StaticCodeValidationRules

Cynapsys Dynamics Ax Team 135


Life Cycle Server
LCS, mthodologie
Life Cycle Server
Microsoft Azure-based administration and collaboration portal that facilitates
application lifecycle management.
Data uploader, integrates with commonly used services such as Visual Studio
Team Services (VSTS)
Supports multiple environments (i.e. Dev, QA, UAT, Production).
Support sure steps methodologie.
Integrate with the TFS (Team Foundation Server).
Application Lifecycle Management (ALM)

Cynapsys Dynamics Ax Team 137


Mthodologie

Cynapsys Dynamics Ax Team 138


Reporting
Cynapsys Dynamics Ax Team 140
Dynamics 365 errors
Occures in develomement Environnement
Oneor more error occurred When
right clicking form elements
follow these steps to clear the cache.
1. Delete the contents from the following folders ( the AppData folder is hidden )
1. C:\Users\<>\AppData\Local\Microsoft\Team Foundation
2. C:\Users\<>\AppData\Local\Microsoft\VisualStudio
3. C:\Users\<>\AppData\Local\Microsoft\VSCommon
2. Go to the Visual Studio IDE folder in command prompt and Run the following command devenv
/resetuserdata from the Visual Studio IDE folder.
1. Typical location for 64 bit: C:\Program Files (x86)\Microsoft Visual Studio 10.0\Common7\IDE
2. Typical location for 32 bit: C:\Program Files\Microsoft Visual Studio 10.0\Common7\IDE

Cynapsys Dynamics Ax Team 142


Display method not recognized, because of
module reference
when creating a new form having VendTrans ax a datasource, the build
failed with nine errors. All of these errors are related to display methods
beeing not reconised. in the end of the error text : Are you missing a
module reference.
i checked the model references, and i made sure that the model
Application suite( the model that holds the vendTrand table is refrenced.
but these errors dont disapear.
the error text is for example :
diaplay method tracenum defined on VendTrans, refrenced in data source
'Vendtrans' of form 'VendTransFormCustom', returns type 'TranceNum',
which is not recognized. Are you missing a module reference ?

Cynapsys Dynamics Ax Team 143


Odds in Ax 7
DocumentDescription EDT in SourceDocument model of Sys layer
cant do extension in the same project

Cynapsys Dynamics Ax Team 144


Compare tool

Cynapsys Dynamics Ax Team 145


Conclusion

Cynapsys Dynamics Ax Team 146

Potrebbero piacerti anche