Book Image

Dynamics 365 for Finance and Operations Development Cookbook - Fourth Edition

By : Abhimanyu Singh, Deepak Agarwal
Book Image

Dynamics 365 for Finance and Operations Development Cookbook - Fourth Edition

By: Abhimanyu Singh, Deepak Agarwal

Overview of this book

Microsoft Dynamics 365 for Finance and Operations has a lot to offer developers. It allows them to customize and tailor their implementations to meet their organization’s needs. This Development Cookbook will help you manage your company or customer ERP information and operations efficiently. We start off by exploring the concept of data manipulation in Dynamics 365 for Operations. This will also help you build scripts to assist data migration, and show you how to organize data in forms. You will learn how to create custom lookups using Application Object Tree forms and generate them dynamically. We will also show you how you can enhance your application by using advanced form controls, and integrate your system with other external systems. We will help you script and enhance your user interface using UI elements. This book will help you look at application development from a business process perspective, and develop enhanced ERP solutions by learning and implementing the best practices and techniques.
Table of Contents (18 chapters)
Title Page
Credits
About the Authors
About the Reviewer
www.PacktPub.com
Customer Feedback
Dedication
Preface

Creating a new project, package, and model


Elements in Dynamics 365 for Finance and Operations represent every individual element of AOT such as class, table, form, and so on. Elements in Dynamics 365 for Finance and Operations are stored on disk as XML files; these files contain the metadata and source code for the element. The XML files are the unit of Source Control.

Projects works the same as AX2012, but in D365 an element can be customized only once they are added to a specific Visual Studio project. The project may only belong to one model.

A Dynamics 365 for Finance and Operations model is a group of elements. Standard elements are part of a standard model; you can add them into your model and do customization. A model is a design-time concept. An example of models: warehouse management model, a project accounting model, and more. Models can have one or more projects. Models may only belong to one package.

A Dynamics 365 for Finance and Operations package is a deployment and compilation unit of one or more models. It includes model metadata, binaries, cubes, and other associated resources. One or more D365 packages can be packaged into a deployment package, which is the vehicle used for deployment on UAT and production environments. Packages are packaged into a deployable package file for deployment to Sandbox or production environments. A package can have one or more models. Packages can have references to other packages, just like .NET assemblies can reference each other.

How to do it...

To create a new project, follow these steps:

  1. Open Visual Studio as admin.
  2. On the File menu, point to New, and then click Project.
  3. In the list of template types, expand the Installed node.
  4. Expand the Templates node.
  5. Select the Microsoft Dynamics 365 for Operations category.
  6. Select the D365 Project template.
  7. Enter the name and location for the new project.
  1. Select Create directory for solution if you want to create a new solution for this project, uncheck if you want to add in your current solution.

To create a new model, follow these steps:

  1. Open Visual Studio as admin.
  2. On the Dynamics 365 menu, point to Model management and select Create model.
  1. Give a model, publisher name, and other values:
  1. Now here you can create a new package or select any existing package. We could create a new package and select the required package as referenced packages:
  1. Double-check the summary with details. Select Create new project if you want to create a new project in this model once created. You can mark this model to all your new projects by selecting options:

There's more...

As you saw, there was one more step while creating a model, Select referenced packages. When you create your own package you can select from an existing package to add them as references in your new package. You may need to add some standard package reference if you want to add them into your customization.

Here are the steps to create a new package:

  1. Open Visual Studio as admin.
  2. On the Dynamics 365 menu, point to Model management and select Create model.
  3. Give a model, publisher name, and other values.
  4. On the next step select Create new package
  5. Give a name to your package.
  6. Next select the existing package as a reference to this new package.
  7. Click on Finish.

So now you have your own model with a new package.