Here, you’ll find practical tips, deep technical dives, and real-world solutions for Microsoft Dynamics 365 F&O development. From X++ best practices and debugging tricks to data entities, integrations, and performance optimization, this blog is all about making your F&O journey smoother and more efficient. Whether you’re a seasoned developer or just starting out, there’s something here for you. Stay tuned for hands-on tutorials, expert insights, and the latest F&O innovations! 💡🔥
Translate
Saturday, August 10, 2019
Open Sales Order Clouse Custom Form in Ax 2012 X++
Adding "Code commented by your Name, Date" comments in existing method using x++
\Classes\EditorScripts
Add new below method.
Friday, July 26, 2019
Cannot create a record in Product Modeling Policy (EcoResProductMasterModelingPolicy). Reference: 0, No. The record already exists. In AX 2012 R3
DIXF Product entity returns the following error for every product.
Explanation
DIXF Product entity loaded data into target
data sources based on descending sequence number
(DMFTargetEntityHierarchy.SequenceNo), and EcoResProductMasterModelingPolicy is
the first table to get loaded (Seq. No. 22 out of 22 target data sources).
However, records cannot be inserted into EcoResProductMasterModelingPolicy if it does not have a valid ProductMaster.RecId available for reference.
This makes sense since EcoResProductMasterModelingPolicy is getting populated before EcoResProduct (which also populates EcoResProductMaster to provide a RecId).
Solution
To fix this, I changed the seq. no.
of EcoResProduct to 23, making it the largest value so it will
get selected and populated first in the while loop.
static void EcoResProductSequenceUpdate(Args _args)
{
DMFTargetEntityHierarchy DMFTargetEntityHierarchy;
select forupdate DMFTargetEntityHierarchy
where DMFTargetEntityHierarchy.recid == 5637145349;
if (DMFTargetEntityHierarchy)
{
ttsbegin;
DMFTargetEntityHierarchy.SequenceNo = 23;
DMFTargetEntityHierarchy.doupdate();
info('done');
ttsCommit;
}
}
Wednesday, June 26, 2019
Open a Purchtable form through info log in AX 2012
How to open
Purchtable form from the Info Log.
Job to get distinct display product number in D365FO
In this blog, I will discuss how to get a distinct display product number in Dynamics 365 Finance and Operations. Please see the screenshot below with the source code explanation.
Note: In my case, I have got Item Id and Invent Dim Id from RFQ Lines.
Explanation of source code (1.1):
- Get a purchase request for quotation from RFQCaseId and LineNum.
- Updating inventory dimensions.
- Find or create an inventory dimension.
- Find the inventory dimension combination is order to get the product variant record ID.
- Get the display product number and set it in the info method.
PurchRFQCaseLine line;