web
You’re offline. This is a read only version of the page.
close
Skip to main content

Notifications

Announcements

No record found.

Community site session details

Community site session details

Session Id :
Microsoft Dynamics AX (Archived)

AX2012 R2 Costing Sheet - Costs of Purchase

(0) ShareShare
ReportReport
Posted on by 170

Does anyone out there have experience with the Costing Sheet changes introduced in AX2012 (we are on R2 with CU6)?

Specifically, there is now the ability to create a price type of "Costs of Purchase" and a structure for adding an indirect cost (e.g applied material burden). I can get get this to work by creating an indirect cost with a Surcharge, for example a flat 10% charge for all items. I am unable to get this to work if I use the "Per Item" flag and try to apply different surcharges to different items.

Also, there is an option for creating a "Unit Based" indirect cost, but I cannot get that to work at all (there are also input and output Unit Based costs available in Cost of Goods Manufactured now as well).

My struggle is that I cannot find any documentation on the intended use of these unit based costs, or a comprehensive description of how the Cost of Purchase price is intended to work. If anyone has a document that covers this topic I would greatly appreciate it.

Best regards!

*This post is locked for comments

I have the same question (0)
  • Suggested answer
    Brandon Wiese Profile Picture
    17,788 on at

    Per item is broken in R2 and I believe in CU6 as well.  This something I had to fix in our environment.  We also extended it to be Per vendor, since that's simply an easier way for us to manage the cost factor.

    How good are your development skills?  If I send you specifics, can you implement them into a fix?

  • Verified answer
    Brandon Wiese Profile Picture
    17,788 on at

    I don't recall if this is the whole fix or not.  It is mixed in with a bunch of other fixes and changes to costing.

    The problem is that the item number is lost on the way down through the call stack.

    In Classes\InventCostPurchIndirect\methods\init(), you will find the following code.

    costCalcTransData = CostCalcTransdata::construct('', 0, transdate, 1, indirectData.parmInventSiteId());

    Inspection into the construct method reveals that the empty string is the ItemId parameter.  Go figure.

    Create a new method on the class as follows.

    protected ItemId getItemIdFromIndirectData(InventCostIndirectData _indirectData)

    {

       MapEnumerator   mapEnum;

       ;

       if (_indirectData.parmItemCostGroupRollupListMap())

       {

           mapEnum = _indirectData.parmItemCostGroupRollupListMap().getEnumerator();

           if (mapEnum.moveNext())

           {

               return mapEnum.currentKey();  // found

           }

       }

       return '';  // not found

    }

    then replace the empty string with a call to this.getItemIdFromIndirectData(_indirectData) and that should do it.

    Let me know if this doesn't quite work.  I can keep searching for other pieces.

  • kurtbeers Profile Picture
    170 on at

    Thank you!

  • Brandon Wiese Profile Picture
    17,788 on at

    Does that mean it worked?  Please confirm if you get it working that no additional changes are required.

  • kurtbeers Profile Picture
    170 on at

    Thanks for following up Brandon. I am not a developer, so I cannot verify if the suggested code worked. I do have someone that is going to help me look at this.  I appreciate your confirming that the function is not working properly though, I was trying to find the error in my setup and was struggling without documentation.

    Thank you again, your response is much appreciated.

  • KenR_atl Profile Picture
    5 on at

    Were you able to extend to Per Vendor on the Cost of Purchase?   Were you able to use the Trade Agreement Vendor or the Vendor on the item record?

    We are considering the same change, and would be curious if you ran into any stumbling blocks with it?

    Thanks

  • Suggested answer
    Brandon Wiese Profile Picture
    17,788 on at

    Yes we extended the purchase indirect costs to use vendor in the cost calculation factor table and it has been working fine for almost a year.  We use the vendor from the movement, i.e. the purchase order.

    Basically we created a new Base enum called TableGroupVendorAll and replaced it wherever ItemCode was being stored or supplied in method calls (formerly as just TableGroupAll).  This involves a fair number of tables and classes, but is not a difficult change.  The compiler will catch most of the type errors for you.  Then add the relation to support the lookup of VendAccount when TableGroupVendorAll::Vendor.  The hardest part is passing the values you need (both ItemId and VendAccount) through the classes CostCalcTransData, InventCostPurchIndirect, and InventCostPurchIndirectData (discussed above).  AX out of the box is broken in that it never passes the ItemId down correctly so the per-item cost factors don't work at all, but I think that is discussed in another thread.

  • Community Member Profile Picture
    on at

    Hi,

    Did any of you found a solution on LCS or did you only customized your environment?

    Thanks

  • Robert Stogner Profile Picture
    480 on at

    Thank you, Thank you, Thank you!!  I struggled enough with using percent based cost of purchase surcharges, but I could not get quantity based to work at all in purchasing.  This worked great!

  • Community Member Profile Picture
    on at

    Brandon,  Thanks for the updates and acknowledgement of this situation.  Our requirement is to apply a material overhead cost ($.035) at the unit cost level, list it on the costing sheet, complete form etc. and to impact total unit cost.  Example:  for each item qty add $.035 to the unit cost at the purchase item level (similar to price charges - Incld in price) and only for specific items where this applies.  After much testing, we too can not get the costing sheet to recognize the "per item" selection and where the costing sheet allows for valid entries of the purchase item (table select) and amount.  We have applied the fixes noted but with no net improvement.  I reviewed the BOM calculation white paper and noted where the "per item" check box on applies to BOM items (this implies not purchased items).  I retested using a sub-assembly (BOM item) and entering this item in the calculation setup part of the costing sheet.  This did influence the material overhead by applying the amount/percentage for each purchase item in the sub-assembly.  It took the total usage quantity of the purchased items and extended times the amount - I could get this to work for surcharge/input base etc.  But this does not address the requirement and am a bit confused on what the value would be.

    Anyway,  do you have the code for how to change the costing sheet (BOM calculation) to pick up an amount or surcharge at the purchased item level?  If so,  I would be very grateful.

    BTW - I also tested this functionality in R3 and the capability to apply an overhead rate at the purchased item is not there.

Under review

Thank you for your reply! To ensure a great experience for everyone, your content is awaiting approval by our Community Managers. Please check back later.

Helpful resources

Quick Links

Responsible AI policies

As AI tools become more common, we’re introducing a Responsible AI Use…

Neeraj Kumar – Community Spotlight

We are honored to recognize Neeraj Kumar as our Community Spotlight honoree for…

Leaderboard > 🔒一 Microsoft Dynamics AX (Archived)

#1
Priya_K Profile Picture

Priya_K 4

#1
Martin Dráb Profile Picture

Martin Dráb 4 Most Valuable Professional

#3
Ali Zaidi Profile Picture

Ali Zaidi 2

Last 30 days Overall leaderboard

Featured topics

Product updates

Dynamics 365 release plans