void modifiedRecord()
{
;
//in not equal, update user or manager update field
if(!(MIOSQTable.orig().equal(MIOSQTable)) || !(MIOSQVendReply.orig().equal(MIOSQVendReply)))
{
if(isUser)
MIOSQTable.UserUpdate = NoYes::Yes;
if(isManager)
MIOSQTable.ManagerUpdate = NoYes::Yes;
}
}
2018-10-31
[AX2012] Comparing Two Record
To compare the original and updated (dirty) record, use equal method. Do this below method before write the table record.
2018-10-19
[AX2012] Ledger Dimension Description
display Description getLedgerDimensionDesc()
{
DimensionStorage dimensionStorage;
DimensionStorageSegment segment;
Description dimDesc;
int hierarchyIndex, hierarchyCount;
int segmentIndex, segmentCount;
Name segmentName;
;
dimensionStorage = DimensionStorage::findById(this.LedgerDimension);
if(!dimensionStorage)
return dimDesc;
hierarchyCount = dimensionStorage.hierarchyCount();
for(hierarchyIndex=1; hierarchyIndex<=hierarchyCount; hierarchyIndex++)
{
segmentCount = dimensionStorage.segmentCountForHierarchy(hierarchyIndex);
for(segmentIndex=1; segmentIndex<=segmentCount; segmentIndex++)
{
segment = dimensionStorage.getSegmentForHierarchy(hierarchyIndex, segmentIndex);
if(segment.parmDimensionAttributeValueId()!=0)
{
segmentName = segment.getName();
if(!dimDesc)
dimDesc = segmentName;
else
dimDesc += "-"+segmentName;
}
}
}
return dimDesc;
}
Subscribe to:
Posts (Atom)