Friday, November 26, 2021
get selected record from Lookup
Wednesday, August 18, 2021
ComboBox filter
1. Add Enum control in Form
2 .Enum Contol AutoDeclaration property set to Yes.
3 .in control modified method add below code.
public boolean modified()
{
int ret;
QueryBuildRange range;
;
ret = super();
range = SysQuery::findOrCreateRange(
purchTable_DS.query().dataSourceTable(tablenum(PurchTable)),
fieldnum(PurchTable, PurchStatus));
range.value(queryValue(controlname.selection()));
purchTable_DS.executeQuery();
return ret;}
Friday, June 18, 2021
Some Important function
Get Last Two Characters
Str s = 'AXAPTA';
info(strfmt( subStr(s,strLen(s)-1,strlen(s)));
OutPut : TA
Get First Two Characters
info(strFmt(subStr(s,0,2 )));
OutPut : AX
Friday, December 4, 2020
Validate in UI Builder class
Write below code in your UIBuilder Class
public boolean validatePostingProfile(FormStringControl _control)
{
boolean ret = true;
VendPostingProfile vendPostingProfile;
vendPostingProfile = _control.valueStr();
if(VendLedger::find(vendPostingProfile))
{
if(vendPostingProfile != ' ' )
{
error ('Posting profile does not exist');
ret = false;
}
return ret;
}
call the above method in PostBuild method
dlgpostingProfile.registerOverrideMethod(methodStr(FormStringControl, validate), methodStr(<yourUIBuilderclass>, validatePostingProfile),this);
Tuesday, November 17, 2020
Validation on Empty space through X++
Tables-->InventBatch-->ValidateField
case fieldNum (InventBatch,InventBatchId):
if(strContains(this.InventBatchId," "))
{
ret = checkFailed("Empty space is not Allowed");
}
Tuesday, May 5, 2020
SSRS Expression
=SUM(MAX(Fields!RoundOff.Value,"LedgerVoucher"))
here LedgerVoucher is group name
Serial number on Group by :
syntax:
=RunningValue(<Grouped field>,CountDistinct,”<DataSet>”)
Example:
=RunningValue(Fields!LedgerVoucher.Value,CountDistinct,"SendingBillsDS")
Wednesday, March 4, 2020
call table level lookup method in form
public client static void lookupActiveEmpId(FormStringControl _ctrl)
{
SysTableLookup sysTableLookup = SysTableLookup::newParameters(tableNum(EmplTable),_ctrl);
Query query = new Query();
QueryBuildDataSource queryBuildDataSource = query.addDataSource(tableNum(EmplTable));
queryBuildDataSource.addRange(fieldNum(EmplTable,Active)).value(enum2str(NoYes::Yes));
sysTableLookup.addLookupfield(fieldNum(EmplTable,EmplId));
sysTableLookup.addLookupfield(fieldNum(EmplTable, EmplName));
sysTableLookup.addLookupfield(fieldNum(EmplTable,Active));
sysTableLookup.addSelectionField(fieldNum(EmplTable,EmplId));
sysTableLookup.parmQuery(query);
sysTableLookup.performFormLookup();
}
Form-->Design String Control-->method
public void lookup()
{
EmplTable::lookupActiveEmpId(this);
}
update_recordset with joins
update_recordset with joins update_recordSet storeTransfer setting TransactionId = transfertable.TransferId join transfert...
-
void clicked() { EcoResProductMaster ecoResProductMaster; EcoResProductIdentifier ecoResProductIdent...
-
Network Requirements: Microsoft Dynamics AX can operate on networks that use Internet Protocol Version 4 ( IPv4 ) or Internet Protocol Ve...
-
index : An index is a table-specific database structure that speeds the retrieval of rows from a table. Uses : Indexes are used to impro...

