Showing posts with label inventory turnover. Show all posts
Showing posts with label inventory turnover. Show all posts

Thursday, November 8, 2012

Calculation of the item average availability


Hi all!

This time I will talk to you about the way to calculate average availability over time in AX 2009.

The calculation of the average availability requires the availability of every item code on a specific date (usually at the end of month), but this information seems not available directly in AX 2009.

I found a way to retrieve this information: I create a batch class that runs every day and check if the current day is the last day of the month.
For doing this check I have used the "endMth" function, that works also with leap years

Here's the code:

void Run()
{
    Table1                         table1;
    TransDate                   t = today();
    TransDate                   lastdayofMth;
    ;

    lastdayofMth = endmth(t);
    if (t==lastdayofMth)
    {
       //Insert your code here for populate a custom table with item availability
    }
}

This is part of a custom project I developed for get the Inventory Turnover Index in AX 2009.
(if anyone is interested please do not hesitate to contact me).

See you next time!...