Ledger Dimension D365FO



Ledger Dimension AX2012 & D365FO



In AX -2012 We use DimensionStorage class and method getDynamicAccount to get the Ledger dimension of the following accounts.

For Instance 
DimensionStorage::getDynamicAccount("ABC",LedgerJournalACType::Ledger);
  1. Ledger
  2. Cust
  3. Vend
  4. Project
  5. FixedAssets
  6. Bank
In D365FO  DimensionStorage is removed and the new class introduces LedgerDynamicAccountHelper to get the Ledger dimension of the following accounts.

For Instance 


LedgerDynamicAccountHelper::getDynamicAccountFromAccountNumber("Project-001",LedgerJournalACType::Project);


Support Faryal's Cusine


WBS key for a project activity X++ code



WBS key for a project activity X++ code 



Using following SQL Query you can retrieve all activities of one project.

select PURPOSE,ACTIVITYNUMBER from smmActivities
where ACTIVITYNUMBER in (
select ActivityNumber from SmmActivityParentLinkTable
join projTable
            on  projTable.Recid=SmmActivityParentLinkTable.refRecId
   and  SmmActivityParentLinkTable.parentType=7


   where projTable.ProjId='PROJ-0000003')



Using following AX Query you can retrieve all activities of one project.

    SmmActivityParentLinkTable  activityParentLinkTable;
        ProjTable                   projTable;
        ProjectActivityNumber           projectActivityNumber;
        smmActivities               smmActivities;
         
            
            
            
         while   select PURPOSE,ACTIVITYNUMBER from smmActivities
           exists join activityParentLinkTable
            where activityParentLinkTable.ActivityNumber==smmActivities.ActivityNumber
           exists join projTable
            where projTable.Recid==activityParentLinkTable.refRecId
            && activityParentLinkTable.parentType==smmActivityParentType::Project
            && projTable.ProjId=="PROJ-0000003"
        {
         //   projectActivityNumber=new ProjectActivityNumber();

           // projectActivityNumber.ActivityNumber=activityParentLinkTable.ActivityNumber;
           info(strFmt("%1 %2",smmActivities.Purpose, smmActivities.ActivityNumber));
     //       _objContract.addProjectActivity(projectActivityNumber);
        }

Support Faryal's Cusine


Virtual Fields Vs Computed Fields

  Virtual Field: A virtual field in D365FO is a field that doesn't have a direct representation in the database. It's a field that y...