Quantcast
Channel: Microsoft Dynamics AX Forum - Recent Threads
Viewing all articles
Browse latest Browse all 72043

filter a lookup field

$
0
0

i want to lookup filed QuotationId from table SalesQuotationTable based on my conditions below , conditions work right but when i write this line of code  [sysTableLookup.addLookupfield(fieldNum(SalesQuotationTable,QuotationId),true);] returns all QuotationId in SalesQuotaionTable not QuotationId which i need from my conditions so my question is how to filter filed with these conditions.

public void lookup(FormControl _formControl, str _filterStr)
{
SalesQuotationLine SalesQuotationLine;
SMAServiceOrderTable _SMAServiceOrderTable;
SalesQuotationTable _SalesQuotationTable;

SysTableLookup sysTableLookup;

sysTableLookup = SysTableLookup::newParameters(tableNum(SalesQuotationTable),_formControl);

select * from _SMAServiceOrderTable where _SMAServiceOrderTable.wo_id==SMAServiceOrderTable.wo_id;

select QuotationId,woid from SalesQuotationLine
where SalesQuotationLine.woid==_SMAServiceOrderTable.wo_id
join _SalesQuotationTable
where SalesQuotationLine.QuotationId==_SalesQuotationTable.QuotationId;

{
sysTableLookup.addLookupfield(fieldNum(SalesQuotationTable,QuotationId),true);

}
sysTableLookup.performFormLookup();
}


Viewing all articles
Browse latest Browse all 72043

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>