axapta - Custom lookup select issue -


the idea contruct lookup unique employer name. lookup works fine when select value , select lookup button again , click on place marked in red, there duplicate values, wrong.

kindly refer snippet , snapshot

querybuilddatasource    qbds; query                   query = new query(); formstringcontrol       control = dialog.formrun().controlcallingmethod(); systablelookup          systablelookup =  systablelookup::newparameters(tablenum(vendtable), control); ;  qbds  = query.adddatasource(tablenum(vendtable)); qbds.addgroupbyfield(fieldnum(vendtable,employername)); systablelookup.addlookupfield(fieldnum(vendtable, employername));  systablelookup.parmquery(query); systablelookup.parmuselookupvalue(false); systablelookup.performformlookup(); 

enter image description here enter image descrip![enter image description heretion here]2

make view on table vendtable , field employername and count of recid, base lookup on view.

as shown below custtable , custgroup:

enter image description here

enter image description here


Comments

Popular posts from this blog

Android layout hidden on keyboard show -

google app engine - 403 Forbidden POST - Flask WTForms -

c - Why would PK11_GenerateRandom() return an error -8023? -