Domanda

I'm trying to filter the table by the field "LanguageId" to show only "fr". I made a new method in my form datasource Here is my code

    public void filtr()
{
    DirPartyTable _dirPartyTable;
    select LanguageId from _dirPartytable
       where _dirPartyTable.LanguageId == "fr";
}

When running this code nothing happens. How to invoke it to work?

È stato utile?

Soluzione

You can overwrite the init method of the DirPartyTable datasource and add this code to add a range on languageId with value "fr":

SysQuery::findOrCreateRange(this.query().dataSourceTable(tableNum(DirPartyTable)), fieldNum(DirPartyTable, LanguageId)).value("fr");
Autorizzato sotto: CC-BY-SA insieme a attribuzione
Non affiliato a StackOverflow
scroll top