Skip to main content

Notifications

Finance | Project Operations, Human Resources, ...
Unanswered

How to get property Included column value of data field of table index?

(0) ShareShare
ReportReport
Posted on by 81

Hello,

I want to get the value of the property value Included Column of the data field Qty of the index TransIdIdx of CustInvoiceTrans below.

I was able to get the Datafield(Qty) with DictIndex.includedColumn, but I can't find a way to get the Included Column value of the property in the DictIndex class.

If anyone knows how to get it, could you share it?

Any advice would be appreciated.

  • akshi Profile Picture
    akshi 81 on at
    RE: How to get property Included column value of data field of table index?

    Hi Girish,

    I got the Data field value by this code.

    Dictionary dict;
    DictTable  table;
    DictIndex  idx;
    dict = new Dictionary();
    table = new DictTable(dict.tableName2Id("CustInvoiceTrans"));
    idx = new DictIndex(table.id(), table.indexName2Id("TransIdIdx"));
    
    if(idx.numberOfIncludedColumns())
    {
        for (int k=1; k <= idx.numberOfIncludedColumns(); k  )
        {
            int includedCol = idx.includedColumn(k);
            str includedColName = table.fieldName(idx.includedColumn(k));
             Info(strFmt("IncludedColumn: %1, IncludedColumnName: %2",includedCol, includedColName));
        }
    }


    Do you know how to get the value Yes or No for the Included Column?

  • Anton Venter Profile Picture
    Anton Venter 19,493 Super User 2025 Season 1 on at
    RE: How to get property Included column value of data field of table index?

    Why do you want to do this?

  • GirishS Profile Picture
    GirishS 27,821 Super User 2024 Season 1 on at
    RE: How to get property Included column value of data field of table index?

    Hi Akshi,

    How you got Data field value?

    If you got property of the Data field value, then my assumption will be using the same you can get the included column value right?

    Thanks,

    Girish S.

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

Announcing Our 2025 Season 1 Super Users!

A new season of Super Users has arrived, and we are so grateful for the daily…

Vahid Ghafarpour – Community Spotlight

We are excited to recognize Vahid Ghafarpour as our February 2025 Community…

Congratulations to the January Top 10 leaders!

Check out the January community rock stars...

Leaderboard

#1
André Arnaud de Calavon Profile Picture

André Arnaud de Cal... 291,996 Super User 2025 Season 1

#2
Martin Dráb Profile Picture

Martin Dráb 230,853 Most Valuable Professional

#3
nmaenpaa Profile Picture

nmaenpaa 101,156

Leaderboard

Product updates

Dynamics 365 release plans