The purpose of this blog is for knowledge sharing and connect the relevant audience who are all into Microsoft Dynamics world.
Alfasith AX
اللَّهُمَّ انْفَعْنِي بِمَا عَلَّمْتَنِي، وَعَلِّمْنِي مَا يَنْفَعُنِي، وَزِدْنِي عِلْمًا
Wednesday, October 24, 2018
Tuesday, October 23, 2018
Deploy all the report in CMD for D365
Hi,
1. Run the powershell command prompt as administrator.
2. Paste the code for specific reports.
here my sample is PurchPurchaseOrder.Report
K:\AosService\PackagesLocalDirectory\Plugins\AxReportVmRoleStartupTask\DeployAllReportsToSSRS.ps1 -Module ApplicationSuite -ReportName PurchPurchaeOrder.Report -PackageInstallLocation “K:\AosService\PackagesLocalDirectory”
3. To deploy all the reports.
K:\AosService\PackagesLocalDirectory\Plugins\AxReportVmRoleStartupTask\DeployAllReportsToSSRS.ps1 -PackageInstallLocation “K:\AosService\PackagesLocalDirectory”
Regards,
1. Run the powershell command prompt as administrator.
2. Paste the code for specific reports.
here my sample is PurchPurchaseOrder.Report
K:\AosService\PackagesLocalDirectory\Plugins\AxReportVmRoleStartupTask\DeployAllReportsToSSRS.ps1 -Module ApplicationSuite -ReportName PurchPurchaeOrder.Report -PackageInstallLocation “K:\AosService\PackagesLocalDirectory”
3. To deploy all the reports.
K:\AosService\PackagesLocalDirectory\Plugins\AxReportVmRoleStartupTask\DeployAllReportsToSSRS.ps1 -PackageInstallLocation “K:\AosService\PackagesLocalDirectory”
Monday, October 15, 2018
Sunday, October 14, 2018
Error: "The model element was saved with unparsable source code and cannot be used".
Hi,
This is error because of multiple times changes in the blocks of code. This is the error on building a recent changes which is not affecting by last changes.
Solution.
1. Take a complete old code in to Notepad and save the class and built the object.
2. Now replace this blocks of code with the buffer you have in clipboard.
3. You may save and build now.
Thanks,
This is error because of multiple times changes in the blocks of code. This is the error on building a recent changes which is not affecting by last changes.
Solution.
1. Take a complete old code in to Notepad and save the class and built the object.
2. Now replace this blocks of code with the buffer you have in clipboard.
3. You may save and build now.
Thanks,
Wednesday, June 20, 2018
Relation between ProjPostTransView and PurchOrder
Hi
Add the ProjTransId in to that view from ProjItemTrans.
display PurchId PurchId()
{
PurchLine PurchLine;
ProjItemTransView projItemTransView;
InventTransOrigin inventTransOrigin;
ProjItemTrans projItemTrans;
;
if(this.ProjTransId)
{
select projItemTrans where projItemTrans.ProjTransId == this.ProjTransId;
select PurchLine where PurchLine.ProjTransId == projItemTrans.ProjTransIdRef
&& PurchLine.ItemId == projItemTrans.ItemId;
//select InventTransId from projItemTransView where projItemTransView.ProjTransId == this.ProjTransId
//join inventTransOrigin where inventTransOrigin.InventTransId == projItemTransView.InventTransId;
return PurchLine.PurchId;
}
else return "";
}
Thanks,
Add the ProjTransId in to that view from ProjItemTrans.
display PurchId PurchId()
{
PurchLine PurchLine;
ProjItemTransView projItemTransView;
InventTransOrigin inventTransOrigin;
ProjItemTrans projItemTrans;
;
if(this.ProjTransId)
{
select projItemTrans where projItemTrans.ProjTransId == this.ProjTransId;
select PurchLine where PurchLine.ProjTransId == projItemTrans.ProjTransIdRef
&& PurchLine.ItemId == projItemTrans.ItemId;
//select InventTransId from projItemTransView where projItemTransView.ProjTransId == this.ProjTransId
//join inventTransOrigin where inventTransOrigin.InventTransId == projItemTransView.InventTransId;
return PurchLine.PurchId;
}
else return "";
}
Thanks,
Monday, March 5, 2018
Joining a table in datasource without adding the table in to the form data source in AX 2012
Hi,
In my case I needs to add the purchTable as range but I dont want to add the table in that form datasource.
I added the below code in the PurchLine init().
public void init()
{
Query query = new Query();
QueryBuildDataSource purchTableDS,purchLineDS;
QueryBuildRange activityNum,purchStatus;
ProjBudgetLine projBudgetLine;
Query queryDB;
QueryBuildDataSource qbdsPurchLine;
QueryBuildDataSource qbdsPurchTable;
super();
projBudgetLine = element.args().record();
qbdsPurchLine = this.query().dataSourceTable(tableNum(PurchLine));
qbdsPurchLine.addRange(fieldnum(PurchLine, ActivityNumber)).value(queryvalue(projBudgetLine.ActivityNumber));
qbdsPurchTable = qbdsPurchLine.addDataSource(tableNum(PurchTable));
qbdsPurchTable.addLink(fieldNum(PurchTable, PurchId), fieldNum(PurchLine, PurchId));
qbdsPurchTable.addRange(fieldnum(PurchTable, DocumentStatus)).value(queryValue(DocumentStatus::PurchaseOrder));
}
In my case I needs to add the purchTable as range but I dont want to add the table in that form datasource.
I added the below code in the PurchLine init().
public void init()
{
Query query = new Query();
QueryBuildDataSource purchTableDS,purchLineDS;
QueryBuildRange activityNum,purchStatus;
ProjBudgetLine projBudgetLine;
Query queryDB;
QueryBuildDataSource qbdsPurchLine;
QueryBuildDataSource qbdsPurchTable;
super();
projBudgetLine = element.args().record();
qbdsPurchLine = this.query().dataSourceTable(tableNum(PurchLine));
qbdsPurchLine.addRange(fieldnum(PurchLine, ActivityNumber)).value(queryvalue(projBudgetLine.ActivityNumber));
qbdsPurchTable = qbdsPurchLine.addDataSource(tableNum(PurchTable));
qbdsPurchTable.addLink(fieldNum(PurchTable, PurchId), fieldNum(PurchLine, PurchId));
qbdsPurchTable.addRange(fieldnum(PurchTable, DocumentStatus)).value(queryValue(DocumentStatus::PurchaseOrder));
}
Subscribe to:
Posts (Atom)
Get a table ID in SQL / table browser - D365
Hi select ID from SysTableIdView where SysTableIdView .Name = 'CustTable' <URL>/?cmp=<CompanyID>&mi=sysTableBrowser...
-
Hi, AccountingDistribution ( accounting distribution 7452 ) AccountingDistributionEventTmp ( accounting distribution 100001 ) Accountin...
-
//< What is GUID> // GUID 16 bit large range of alphanumeric similar to RecID to treat as primary key of a table. static void CreateG...


