• Skip to main content
  • Skip to primary sidebar
  • Home
  • About
  • Recommended Readings
    • 2022 Book Reading
    • 2023 Recommended Readings
    • Book Reading 2024
    • Book Reading 2025
  • Supply Chain Management Guide
  • PKM
  • Microsoft Excel

Ali Raza Zaidi

A practitioner’s musings on Dynamics 365 Finance and Operations

D365OF

Allow duplicate check Global Address Book Dynamics 365 for finance and operations.

May 31, 2019 by alirazazaidi

Dynamics 365 for finance and operations provide functionality of check Party Name already exists in Global Address book, So End user can select instead create a new one if required.

Here is video I shared this functionality in small less then 5 minutes series.

 

 

unable to read beyond the end of stream Dynamics 365 for finance and operations

April 25, 2019 by alirazazaidi

After deployment of custom report on my  Dev one box. I faced this error when I run the report for testing. IIS restart, Project compilation and Service restart did not solve the problem.
“

unable to read beyond the end of stream

“
Solution was simple, Build the full model.

Add Financial dimension to Customer/Vender with X++ Dynamics 365 for finance and operations

April 23, 2019 by alirazazaidi

Small tip, I used following code snippet to add financial dimension in Customer / Vendor, You can extend this code by adding more dimension and values on Containers in following code snippet.
public class  iaxFinancialDimensionHelper
{
    Public static DimensionDefault ProjectDimension(ProjId _ProjId)
    {
        DimensionAttributeValueSetStorage valueSetStorage = new DimensionAttributeValueSetStorage();
        DimensionDefault result;
        int i;
        DimensionAttribute dimensionAttribute;
        DimensionAttributeValue dimensionAttributeValue;
        container conAttr = [“Projects”];
        container conValue = [_ProjId];
        str dimValue;
        for (i = 1; i <= conLen(conAttr); i++)
        {
            dimensionAttribute = dimensionAttribute::findByName(conPeek(conAttr,i));
            if (dimensionAttribute.RecId == 0)
            {
                continue;
            }
            dimValue = conPeek(conValue,i);
            if (dimValue != “”)
            {
                // The last parameter is “true”. A dimensionAttributeValue record will be created if not //found.
                dimensionAttributeValue =
dimensionAttributeValue::findByDimensionAttributeAndValue(dimensionAttribute,dimValue,false,true);
                // Add the dimensionAttibuteValue to the default dimension
                valueSetStorage.addItem(dimensionAttributeValue);
            }
        }
        result = valueSetStorage.save();
        return result;
    }
}
Reference : Internet. possible Dynamics forum. it works for me.

The field with ID ‘0’ does not exist in table Dynamics 365 For finance and operations

April 11, 2019 by alirazazaidi

Hi all, I face this error, while extended existing custom report. I added some fields in temp table, after update logic in dp class, On report data set update.

But at run time report shows this error. While debugging the code, I found the error occur on mapping the new fields in temp table.

 

Solution :

I build the whole model. After that error was removed.

 

An error occurred during report data sets execution D365 For finance and operations

April 11, 2019 by alirazazaidi

Hi all, small tip. I faced this issue, when I extend the custom report in D365 for finance and operations. During development on onebox

 

 

Solution was simple,

  • restart IIS services
  • Restart Reporting Services.

Happy Daxing.

How to copy financial dimension form one object to other. Dynamics 365 For finance and operations

March 27, 2019 by alirazazaidi

Hi all, In some cases we can need to copy  financial dimension from one object to  other for example Customer to Sales order or Vendor to purchase order.

In Ax 2012  it little easy. But in D365 For finance and operations, it is little bit tricky.

 

I did this with following code snippet.  With the help of out of box. LedgerDimensonDefaultFacade class i used the merge default dimension method and passed same table dimension in form and to dimension.

Result is interesting.

 

 

 salestable.DefaultDimension= LedgerDimensionDefaultFacade::serviceMergeDefaultDimensions(CustTable.DefaultDimension,CustTable.DefaultDimension);

Calling menu name in Extensions Dynamics 365 for finance and operations

March 23, 2019 by alirazazaidi

In Ax 2012 we get menu name with element.Args().CallMenu name, using  taking decision on menu name.

 

But same logic we need to apply in Extension. But in D365 For finance and operations we did not overlay. Following code snippet helps me to implement similar logic in Extension.

 

 

[ExtensionOf(formStr(CustTable))]

final class IaLogisticsContactInfoGrid_Extension

{

 

 

/// <summary>

///

/// </summary>

/// <param name=”sender”></param>

/// <param name=”e”></param>

[FormEventHandler(formStr(LogisticsContactInfoGrid), FormEventType::Initialized)]

public static void LogisticsContactInfoGrid_OnInitialized(xFormRun sender, FormEventArgs e)

{

 

FormRun formRun = sender;

 

;

 

info(formRun.args().menuItemName());

}

 

}

Paging in Query X++ Dynamics 365 for finance and operations

March 4, 2019 by alirazazaidi

For paging in X++ Query. There are three steps required. Rest of Query Code is same.

We have to set following things in Query data source

  • Set Sort field in Query data Source.
  • Paging position property of QueryRun is set to true.
  • Add page range with starting position and number of records in QueryRun

Here is code snippet

 

  QueryBuildRange qbr,qbrStartDate,qbrEndDate;
QueryBuildDataSource qbd;
IAPageSize EnumPageSize;

QueryRun        qr;

Query           query = new Query();

Int pageSize = 2;

 

qbd = query.addDataSource(TableNum(ProjPlanVersion));
qbd.addOrderByField(fieldNum(ProjPlanVersion,HierarchyId));

qr = new QueryRun(query);

qr.enablePositionPaging(true);
            CurrentPageNumber =1;
            startingposition = CurrentPageNumber * pagesize;
            qr.addPageRange(startingposition, totalRows);
while(qr.next())

 

{

 

Info (“”);

}

How to capture Fiddler logs for Dynamics 365 for finance and operations

February 21, 2019 by alirazazaidi

Here is another tip, how to capture for Finance and operations. You can download fiddlerCap from below link

 

http://www.telerik.com/fiddler/fiddlercap

 

 

Data source filter using extension Dynamics 365 for finance and operations

February 4, 2019 by alirazazaidi

Hi every one, Today I have very small tip. During customization we need to add filters at run time. Specially in the case of inquiry forms. But Now we have to work with extension. Extensions are much more powerful then over layering.

 

So first one thing to copy Datasource  OnQueryEXecuting event. And paste in Extension class.

The sample code snippet is here.

 

 

 

 [FormDataSourceEventHandler(formDataSourceStr(HcmDiscussion, HcmTopicRef), FormDataSourceEventType::QueryExecuting)]

public static void HcmTopicRef_OnQueryExecuting(FormDataSource sender, FormDataSourceEventArgs e)

{

FormRun          HcmDiscussionForm = sender.formRun();

sender.query().dataSourceName(sender.name()).addRange(fieldnum(HcmTopicRef,     HeadingRefRecId)).value(queryValue(_heading.RecId));

}

« Previous Page
Next Page »

Primary Sidebar

About

I am Dynamics AX/365 Finance and Operations consultant with years of implementation experience. I has helped several businesses implement and succeed with Dynamics AX/365 Finance and Operations. The goal of this website is to share insights, tips, and tricks to help end users and IT professionals.

Legal

Content published on this website are opinions, insights, tips, and tricks we have gained from years of Dynamics consulting and may not represent the opinions or views of any current or past employer. Any changes to an ERP system should be thoroughly tested before implementation.

Categories

  • Accounts Payable (2)
  • Advance Warehouse (2)
  • Asset Management (3)
  • Azure Functions (1)
  • Books (6)
  • Certification Guide (3)
  • Customization Tips for D365 for Finance and Operations (62)
  • D365OF (59)
  • Data Management (1)
  • database restore (1)
  • Dynamics 365 (58)
  • Dynamics 365 for finance and operations (135)
  • Dynamics 365 for Operations (165)
  • Dynamics AX (AX 7) (134)
  • Dynamics AX 2012 (274)
  • Dynamics Ax 2012 Forms (13)
  • Dynamics Ax 2012 functional side (16)
  • Dynamics Ax 2012 Reporting SSRS Reports. (31)
  • Dynamics Ax 2012 Technical Side (52)
  • Dynamics Ax 7 (65)
  • Exam MB-330: Microsoft Dynamics 365 Supply Chain Management (7)
  • Excel Addin (1)
  • Favorites (12)
  • Financial Modules (6)
  • Functional (8)
  • Implementations (1)
  • Lifecycle Services (1)
  • Logseq (4)
  • Management Reporter (1)
  • Microsoft Excel (4)
  • MS Dynamics Ax 7 (64)
  • MVP summit (1)
  • MVP summit 2016 (1)
  • New Dynamics Ax (19)
  • Non Defined (9)
  • Note taking Apps (2)
  • Obsidian (3)
  • Personal Knowledge Management (2)
  • PKM (13)
  • Power Platform (6)
  • Procurement (5)
  • procurement and sourcing (5)
  • Product Information Management (4)
  • Product Management (6)
  • Production Control D365 for Finance and Operations (10)
  • Sale Order Process (10)
  • Sale Order Processing (9)
  • Sales and Distribution (5)
  • Soft Skill (1)
  • Supply Chain Management D365 F&O (3)
  • Tips and tricks (278)
  • Uncategorized (165)
  • Upgrade (1)
  • Web Cast (7)
  • White papers (4)
  • X++ (7)

Copyright © 2025 · Magazine Pro On Genesis Framework · WordPress · Log in