Inside D365FO with Mani
Sunday, July 19, 2026
Get base enum lables insted enum ids in SSRS report
Wednesday, July 8, 2026
Get workflow Approver and approval time through code
WorkflowTrackingStatusTable wfTrackingTable;
WorkflowTrackingTable wfTracking;
select firstonly wfTrackingTable
order by wfTrackingTable.CreatedDateTime desc
where wfTrackingTable.ContextTableId == _purchTable.TableId
&& wfTrackingTable.ContextRecId == _purchTable.RecId;
select firstonly wfTracking
order by wfTracking.CreatedDateTime desc
where wfTracking.WorkflowTrackingStatusTable == wfTrackingTable.RecId
&& wfTracking.TrackingType == WorkflowTrackingType::Approval
&& wfTracking.TrackingContext==WorkflowTrackingContext::WorkItem;
Date POApprovalDate = DateTimeUtil::date(wfTracking.CreatedDateTime);
str POApprovedBy = HcmWorker::find(HcmWorker::userId2Worker(wfTracking.user)).name();
Tuesday, July 7, 2026
SSRS report
To make values empty while opening contract and making last given values empty
code:-
In controller class :-
protected void prePromptModifyContract()
{
super();
MyContract contract = this.parmReportContract().parmRdpContract() as MyContract;
if (contract)
{
contract.parmFromDate(dateNull());
contract.parmToDate(dateNull());
contract.parmPRNumber(null);
}
}
Sunday, July 5, 2026
Maintenance mode in d365fo
Scenario:- Generally For activating some configurations maintenance mode is required .
This can be done in two ways
1) From LCS
2) SQL procedure
We discuss here 2 step
SQL procedure
Step1) First of all , run this script
select * from SQLSYSTEMVARIABLES where PARM = 'CONFIGURATIONMODE'
result :- value field 0=normal and 1= maintenance mode
Step2) To turn into maintenance mode run the below script
update SQLSYSTEMVARIABLES SET VALUE = 0 where PARM = 'CONFIGURATIONMODE'
Step3) DO iisreset in commandprompt
Step4) do db sync
visualstudio>extensions>syncorinzedb
Step 5) Now after db sync env will be in maintence mode
Note:- after activating and put maintenance mode back to normal by following same procedure but with 0
Wednesday, July 1, 2026
Navigate to a specific legal entity through code
code:-
appl.setDefaultCompany(Legalentitycode, false);
Wednesday, June 24, 2026
Get product receipt details from posted invoice
code:-
sql:-
select DISTINCT vendPackingSlipTrans.PACKINGSLIPID from vendInvoiceTrans
inner join vendInvoiceJour
on vendInvoiceTrans.PurchID = vendInvoiceJour.PurchId and
vendInvoiceTrans.InvoiceId = vendInvoiceJour.InvoiceId and
vendInvoiceTrans.InvoiceDate = vendInvoiceJour.InvoiceDate and
vendInvoiceTrans.NumberSequenceGroup = vendInvoiceJour.NumberSequenceGroup and
vendInvoiceTrans.InternalInvoiceId = vendInvoiceJour.InternalInvoiceId
inner join vendInvoicePackingSlipQuantityMatch
on vendInvoicePackingSlipQuantityMatch.InvoiceSourceDocumentLIne = vendInvoiceTrans.SourceDocumentLine
inner join vendPackingSlipTrans
on vendPackingSlipTrans.SourceDocumentLine = vendInvoicePackingSlipQuantityMatch.PackingSlipSourceDocumentLine
and vendInvoiceJour.LEDGERVOUCHER='pass your journal vocuher'
Monday, May 11, 2026
Assign roles through ssms in d365fo
Step1;- Here my Role name I want to assign is System admin
SELECT RecId,* FROM SecurityRole WHERE Name = 'System administrator';
step 2:- User name here is sai and pass recid from above to below query
insert into SECURITYUSERROLE (USER_, SECURITYROLE, ASSIGNMENTSTATUS, ASSIGNMENTMODE)
VALUES ('sai', 171,1,1);
Thats it!! refresh and check
For deleting of roles through SSMS
Step1:-SELECT RecId,* FROM SecurityRole WHERE Name = 'System administrator';
pass recid from above to below query
Step 2:-DELETE FROM SECURITYUSERROLE WHERE USER_='sai'and SECURITYROLE=171;
Thank you!!
Get base enum lables insted enum ids in SSRS report
Generally in ssrs report to get baseenum labels instead basenum element id , we can do that in two ways Way1) Take a string field in Tmp ta...
-
Scenario:-Today we see in this blog how to create App Registration in Azure for D365fo integrations that might be import integration or ex...
-
Scenario:-In this blog today we see how to import 2019Visual studio D365fo projects into 2022Visual studio Generally we can import 2019Vi...
-
Scenario :-In this blog we will see import a file through recurring integrations via Logic Apps Step1:-Go to D365fo Data management wor...