Categories
Dynamics NAV HOW TO Microsoft

HOW TO calculate the Day of the Year number in C/SIDE

You can calculate the Day of the Year number in C/SIDE by the difference between the date (in my example I use the current date defined by the operating system using the function TODAY) and the first day of year of the date using the CALCDATE function. You need to add 1 to the result to include the day of the date that you are using.

HOW TO calculate the Day of the Year number in C/SIDE

[sourcecode lang=”Cside”]
Number := TODAY-CALCDATE(‘<-CY>’,TODAY)+1;
[/sourcecode]

If you need it as Text you need to convert it using the FORMAT function
[sourcecode lang=”Cside”]
String := FORMAT(TODAY-CALCDATE(‘<-CY>’,TODAY)+1);
[/sourcecode]

Did my HOW TO help you? Leave a reply.

Categories
Dynamics NAV Microsoft

Encryption key was not found.

Encryption key was not found.

When you try to insert a new Credit Card in Microsoft Dynamics NAV 2013 appears the above error message.

Encryption key was not found

Solution:

  1. In the Search box, enter Payment Services Connection Setup, and then choose the related link.
  2. On the Actions tab, in the Encryption group, choose Generate Key to generate the encryption key that is stored on the Microsoft Dynamics NAV Server.

Experience: I suggest you if you use the Generate Key functionality to download and store in a secure backup the key generated using the button Download Key on the Actions tab, in the Encryption group.

Reference: How to: Set Up a Payment Services Connection

Did my solution solve your problem? Leave a reply.