Posts tagged with: Microsoft Dynamics AX 2012 R2

#TipADay: Copying Data Between Companies using Excel Add-in

Hello everyone

Here is little tip on how to migrate data through Excel Add-In  . Through Excel Add-in you have the option of selecting what instance, partition, and company that you want to upload and publish to.

Let us work on how we can use the Excel Add-In to copy data between entities.

I have not loaded all of my base data, so we will use our main company as the template to load the data.

1

From the Dynamics AX tool, select the Options button and select your base company from where the data will be copied

To create a linked worksheet within Excel, select the Dynamics AX bar, and then from the drop down menu of the Add data button, click on the Add Tables option

2

This will open up a table selection dialog box. Then select the table that you want to add in sheet

3

You will initially have no records showing. To view all of the data that is in the company, select the Refresh button

4

Now change the Legal Entity that will be used just by selecting it from the drop down list.

6

Then we will save the data from  original company for reference. This will make it easier to cut and paste the data back into the new company. So we just select all of the original table, and then copy it.

7

Now that we have the template data saved we can continue on. Return back to the linked table, and then select the Refresh All option there is no data in the other company then the linked table will be blank.

8

And  now you can see in the below image, there is no data in the other company so linked table will be blank. Select the template data that you saved and then paste it into the linked table.

23

Now from the Publish menu, select the Publish All option

10

Now you can check the Publishing Status ,Your data will be copied from one company to another.

Try this tip, Copy a lot of the base data from another existing company, and  save your time

Enjoy Reading!


#TipADay: Day 2: Importing Data to Microsoft Dynamics AX 2012 using Excel Add-in

Excel is a great spreadsheet tool and the AX 2012 Add in is even more wonderful. It allows to publish information/data back to Dynamics AX 2012 without any changes in AX 2012  configuration.  In this functioned example, I will show how you can use the Dynamics AX Excel Add-In to update your data. 

Before we start working on Microsoft Excel, we need to make sure that we have the Dynamics AX Excel Add- in installed. If you open up Excel and there is a Dynamics AX tab, then you are fine. If not, you will need to install it.

Lets try and import Chart of Accounts in Dynamics AX 2012. To do that, follow these simple steps:

Step 1: Go to Dynamics AX Excel Tab in the Excel

E1

Step 2: Select Add Data > Add table

e2

Step 3: Select Main Account Table

e-3

Step 4: Drag important columns that you want to update

e-4

Step 5: Enter your data in the fields

e-5

Step 6: Select Publish to import the records in AX

e-6

It will also create a new sheet called Dynamics AX Status which will show you how many records were updated, and also any errors –if they occurred.

Step 6: If we return back to Dynamics AX, then we will see the data  has been uploaded.

e-7

Hope this little tip helps you. Leave me your feedback and comments!


Questionnaires: How to create Questionnaires in Dynamics AX 2012

This is the second post in the series related to Questionnaires in Microsoft Dynamics AX 2012.

Questionnaires are not difficult; they are just extremely flexible. In an ERP solution, you may think that standard and/or best practices should be part and parcel; but Microsoft Dynamics AX 2012 offers some features that are not only extremely flexible, but they allow for a huge amount of creativity as well!

Do you realize that questionnaires could be used for literally anything? One such example is the little case we had talked about last time; a customer opening form. In a real life scenario, a Sales Person sends a request to an Accounts Receivables Manager to create a customer within Dynamics AX 2012. Some preliminary information is requested from this Sales Person as part of the standard operating procedures.

Let us now see how a questionnaire is formulated:

Step 1: Plan your questions for the questionnaire.

We have three questions we need to ask: Customer Name, Customer Contact Number, Payment Terms.

Step 2: Decide on the Types of Answers that will be received.

Customer Name and Customer Contact Number are simple text fields; Payment Terms would be a radio button.

Step 3: Take the “Choice” Type of questions and formulate your answer groups:

Home > Common > Questionnaires > Design > Answer Groups

Create a New Answer Group: Payment Terms

answer group

Now click on Answers and create your answer list:

We created two answers: Cash, Credit:

Answers

 

Step 4: Now, create your questions and select the different answer groups where applicable:

Home > Common > Questionnaires > Design > Questions

Questions

You’re almost done!

The deal with questions, answers, answer groups and questionnaires is that you create standard solutions for each and then mix and match where required. Say for example, you have several trainings or courses that your company offers. You could create questions that could be mixed/matched as necessary, on several questionnaires to assess these trainings. Makes sense?

Step 5: Now, create your questionnaire for use:

Home > Common > Questionnaires > Design > Questionnaires

Questionnaire

Now click on Questions and add the ones that you had created in step 4.

You’re done!

I used these questionnaires in the Cases that Dynamics AX 2012 has; you could use them for any other purpose.

The above tutorial is very simplistic in nature because of the nature of the work that was needed in the questionnaires. More complicated questionnaires can be created as well to add conditional questions, scoring and evaluation criteria; but more on that later!

Was this tutorial of help? Do leave some comments in case you have any questions.

 

 


Dynamics AX 2012: Questionnaires, what are they and why you should use them

In this two part tutorial, we shall explore and evaluate the true potential of the questionnaires in AX2012. Even though Microsoft Dynamics AX 2012 offers a wide variety of mainstream features in relevant modules apt for a tier one ERP solution; some little known features can help you explore the little nooks and crannies that will make your life a little easier. One such feature is questionnaires in Dynamics AX 2012.

Questionnaires are not lengthy pages of questions that your user will have to fill out. Rather, small checklists, one off questions, evaluations, and even scripts for standardized attendance towards service can be made part of, and through questionnaires. Literally anything can be set up in this tiny function:

  1. Evaluation of a course attended by trainees
  2. Employee performance appraisals
  3. Employee satisfaction surveys
  4. Customer surveys
  5. Vendor evaluation or assessment questionnaire

When designing a questionnaire, some key elements required include:

  1. The type of questionnaire for the question – the area where this question will be used (such as employee evaluation, procurement, etc.) – questions and questionnaires are set up separately and then combined before distribution
  2. Input Type: the type of input such as integer– questions and questionnaires are set up separately and then combined before distribution
  3. Answer Groups: Answer groups are the groups based on which questions can be answered
  4. Instruction: You can guide your user to fill out questionnaires according to some specific instructions (example: script for the person who provides troubleshooting service on phone)
  5. Media Type: type of media that can be attached the question
  6. Rights: You can restrict the questionnaire to a particular group of people (Employees, Contacts – Vendor or Customer, Applicants).

Based on the results gathered, statistics can be calculated and you can generate reports for the answers received on the questionnaires.

This was a little overview on how questionnaires function in Microsoft Dynamics AX 2012. In the next blog post, we shall evaluate a little scenario where the Sales Department fills out a questionnaire for customer evaluation.

This scenario includes the following elements:

  1. New Customer Opening Request
  2. Sales Department generates request
  3. Sales Department fills out questionnaire
  4. Finance Department evaluates request and questionnaire before opening new customer.

We shall only see the questionnaire part of the above scenario.


Calling table insert stops the AX service AX2012

Recently, I faced an issue when calling table insert from code. Every time I executed the statement table.insert() the service of dynamics AX2012 was stopped.

There may be two reasons of this issue.

1-      The RecIds of that particular table tables is getting duplicated, in case if you inserted the data to  that particular table from SQL and it picked the old RecId that are not generated by your current AOS.

2-      The table is not well synchronized.

In my case, synchronizing the table resolved the problem.

Happy DAXing!


Exchange Currency Service Provider

Exchange currency service provider is OOTB available in MS Dynamics AX and by default three AX provide three service exchange provider i.e. Central Bank of the Russian Federal, Central bank of Europe and Lithuanian Bank.

Following is the below screen for Exchange Rate provider which is Available in General Ledger Module

Path: General ledger /setup /Configure exchange rate providers

You must first set up the exchange rate provider you want to use, and AX 2012 R2 comes with 3 providers ready to use in General Ledger -> Setup -> Currency -> Configure Exchange Rate Providers:

fk

fk01

There is reset value option also available to restore default value.

After adding exchange rate provider run this service through batch Job exchange service as shown in below screen

Path: General ledger / Periodic / Import currency exchange rates

Import currency exchange rates batch job take Exchange rate type and exchange rate provider. If exchange rate type is not created then create it from General ledger / setup / Exchange rate type.

Prerequisite:

Before going to run Currency exchange batch job, make sure that all mentioned Exchange currency must create once in exchange rate type.

fk02

Run this batch job

fk03

After running Service provider batch job see today’s exchange currency rate in General ledger / setup / Exchange rate type.

fk04


Delete All the Transactions in a Company by keeping the Master Data intact Dynamics AX

Sometimes, you may have a requirement to delete all the transactions in a company while keeping the Master data as it is.
In order to achieve this you can duplicate the company and run SysDatabaseTransDelete class, which will delete all the transactions in the related company while keep the master data intact.

1. Press Ctrl + D.
2. Open Class node in AOT.
3. Find SysDatabaseTransDelete class, right click open, it will show the related company from which you want to delete the transactions.

transactions

Note : Before performing the above steps on production please do it in test so you can come to know what exactly you achieve.


Usage Data User Specific Report Error Dynamics AX 2012

th3Sometimes, you might face the error in which some reports like “Summary trial balance” report in general ledger will not execute.

In order to resolve this error you need to delete the related records from SysLastValue table. You cannot find this table in AOT so go to SysLastValue form, open data source node, right click and browse table data.

Filter the table with the UserId who is facing the above error, the ElementName with the related element in error and the related company name.

Delete that particular record by Alt+F9 and restart the client.

You can take the backup of the SysLastValue table if you are performing the above actions in production environment.

Note : This table contains the usage data and deleting the records unnecessarily can reset the user saved settings.

Happy DAXing!


Region as an Internal Organisation

System should allow users to create Region within the internal organization hierarchy. For this we have to do some customization

First create new operating unit type element in OMOperatingUnitType base enum

f1

OMOperatingUnitType is used in OMOperatingUnit tables so we need to Restore OMOperatingUnit tables.

Create new View which named as DimAttributeOMRegion as shown in below screen

f2

 Create Internal Region Organization type

Organization Administration > Common > Organization > Internal Organization

Create new region from Internal Organization action pane button as shown in below screen

f3

Click Ok

f4

General Ledger > Setup > Financial Dimensions > Financials Dimensions

Newly created organization should appear within Financial Dimension Form and could be used throughout AX.

f5


Customize Existing Number Sequence to Fiscal Year Number Sequence

Here we are customizing existing Number sequence and convert it in to Fiscal year number sequence Many customer demands for Purchase order creation with automatic year means how to add year to a number sequence in AX2012, e.g. to generate IDs such as 2013-xxxxx and 2014-xxxxx, that would automatically use the current year. Some people understand that number sequence scopes should allow that, but they don’t know how, from very little bit of customization we can automate purchase order number sequence with year

Customize Purchase order Number Sequence Class:

Add fiscal calendar parameter in NumberSeqModulePurchaseIOrder (LoadModule) method as shown in below screen

 datatype.addParameterType(NumberSeqParameterType::FiscalCalendarPeriod, true, true);
fk1

Load NumberSeqModulePurchaseIOrder (Load Module) method Through Job

 NumberSeqModulePurchaseOrder NumberSeqModulePurchaseOrder = new NumberSeqModulePurchaseOrder();
NumberSeqModulePurchaseOrder.load();
fk2

Before going to run the Job, Remove purchase order existing scope parameter record in NumberSequenceDatatype table, if we don’t remove previous Purchase order scope parameter record it will not effect in Segment configuration as shown below

CEU/Organization administration/Number Sequence/ Segment configuration

fk3

Add Fiscal Year Relation to PurchParamater Table:

CEU/Procurement and sourcing/procurement and Sourcing parameters

fk4

We have customized procurement and Sourcing parameters form for Purchase order Fiscal Number sequence, because we need to select which Fiscal year the purchase order is created every year.

Add fiscal year table relation to PurchParamter table

fk5

Add a fiscal year Field on Procurement and Sourcing parameters form

fk6

Customize Purchase Order Number Sequence Table (PurchParameter):

Add following code in Purchase order Number sequence Parameter table method (numRefPurchId), in this existing method we have change code according to fiscal year.

static client server NumberSequenceReference  numRefPurchId(TransDate _date = systemdateget())
{
   //
   PurchParameters PurchParameters;
   NumberSeqScope  scope;

select firstOnly PurchParameters; // get Selected fiscal year in 
                                  // procurement and    Sourcing parameters Form 

   scope = NumberSeqScopeFactory::CreateDataAreaFiscalCalendarPeriodScope
                            (curext(),FiscalCalendars::findPeriodByPeriodCodeDate(FiscalCalendar::findByCalendarId(PurchParameters.FiscalCalendar).RecId, _date).RecId);
   //

     return NumberSeqReference::findReference(extendedTypeNum(PurchId),scope);
}
fk7

Fiscal Year Number Sequence Configuration

 

General ledger -> Setup -> Fiscal calendars.

Create a new Fiscal year or use existing Fiscal year, but In our case we have created our own Fiscal year for Ten years because we need to create Purchase order automated for Ten years

fk8

If you want to add more years follow below screen.

fk9

Click the Calendar -> Calendar year -> New fiscal year button.

Change Copy from last fiscal year from ‘true’ to ‘false’.

Change Unit from ‘Months’ to ‘Years’.

Click the Create button.

Close the Fiscal calendars form.

Number sequences creation

 

fk10

 

Click Area Page node: Organization administration -> Common -> Number sequences -> Number sequences. Click the Number sequence -> New -> Number sequence button.

fk11

Change Number sequence code from ” to ‘POFiscal’.

Change Name from ” to ‘2013’.

Change Scope from ‘Shared’ to ‘Company and Fiscal calendar period’.

Change Company from ” to ‘ceu’.

Change Calendar from ” to ‘FiscalYear’.

Change Fiscal year from ” to ‘2013’.

Change Period name from ” to ‘Period 1′.

fk12

 

Make it very clear that we are creating PO number sequence for the year 2013 and we have to create PO number sequence again for Year 2014, 2015, 2016.xxxxxx 2023 with same Number sequence Code i.e. ‘POFiscal’  as shown in below screen for Year 2014

fk13

 

Creating Purchase orders:

Before going to create Purchase order make sure that Fiscal year must be selected in Procurement and sourcing Parameter form which we have customized earlier above

fk14

 

This selected Fiscal year must be same which we have selected in creating Purchase order Fiscal year Number Sequence.


Pages:12