web
You’re offline. This is a read only version of the page.
close
Skip to main content

Notifications

Announcements

No record found.

Community site session details

Community site session details

Session Id :
Microsoft Dynamics AX (Archived)

Using Product Attribute Value in SysLookupMultiSelectGrid

(0) ShareShare
ReportReport
Posted on by 1,214

Hi. I'm building a Multi-select lookup filtering for a SSRS Report. The report needs filtering by Product Type values, where "Product Type" is an item Attibute. So I need to fill the multi-select lookup with Product Type Attribute Values.  

The thing is, I only need the Product Type values to fill in the lookup list. 

I understand from here is the best way to get attribute values. Method below is my approach to fill the multi-select lookup:

private void itemProductTypeLookup(FormStringControl _control)
{
AttributeValueText attributeValueText;
EcoResProductAttributeValue ecoResProductAttributeValue;
InventTable inventTable;
EcoResAttribute ecoResAttribute;
EcoResValue ecoResValue;
Query query;
container conItemProductType;

while select ecoResProductAttributeValue
where ecoResProductAttributeValue.Product == inventTable.Product
join Name from ecoResAttribute
where ecoResAttribute.Name == "Product Type" && ecoResAttribute.RecId == ecoResProductAttributeValue.Attribute
join ecoResValue
where ecoResValue.RecId == ecoResProductAttributeValue.Value
{
attributeValueText = ecoResValue.value();
}


msCtrlProductType = SysLookupMultiSelectGrid::construct(_control, _control);

msCtrlProductType.run();
}

How can I insert the attributeValueText values into the lookup grid? The normal approach would be using msCtrlProductType.parmQuery() method but EcoResProductAttributeValue is invisible in AOT and cannot be used in a regular query. 

Thank You.

*This post is locked for comments

I have the same question (0)
  • HAIRUL HAZRI Profile Picture
    1,214 on at

    My bad. EcoResProductAttributeValue is not a Table, but a View. So I got to build a query and this issue is fixed. Cheers.

Under review

Thank you for your reply! To ensure a great experience for everyone, your content is awaiting approval by our Community Managers. Please check back later.

Helpful resources

Quick Links

Responsible AI policies

As AI tools become more common, we’re introducing a Responsible AI Use…

Neeraj Kumar – Community Spotlight

We are honored to recognize Neeraj Kumar as our Community Spotlight honoree for…

Leaderboard > 🔒一 Microsoft Dynamics AX (Archived)

#1
Martin Dráb Profile Picture

Martin Dráb 4 Most Valuable Professional

#1
Priya_K Profile Picture

Priya_K 4

#3
MyDynamicsNAV Profile Picture

MyDynamicsNAV 2

Last 30 days Overall leaderboard

Featured topics

Product updates

Dynamics 365 release plans