Forums

Find answers, ask questions, and connect with our
community all around the world.

Home Forum Omnis General Forum datagrid filters have no effect on grid’s datalist

  • datagrid filters have no effect on grid’s datalist

    Posted by Uwe Smidt on January 11, 2026 at 11:00 am

    Dear $all,
    I am using $multifilter on a datagrid control based on dataname=ilDataList.

    When I apply a filter, it does not seem to have an effect on ilDataList, e.g. when I try to export the filtered list, it will export the complete, unfiltered ilDataList.

    When I calculate the number of lines shown in the datagrid to be displayed in the footer with
    $updatefooterrow: Quit method <b style=”font-family: inherit; font-size: inherit;”>ilDataList.$linecount

    it will give me the total no of records of the ilDataList, not he filtered list.

    How do get ilDataList to reflect the filtered datagrid?

    Uwe Smidt replied 2 months ago 2 Members · 3 Replies
  • 3 Replies
  • Uwe Smidt

    Member
    January 21, 2026 at 6:47 am

    Sometimes it just takes some RTFM, and a problem is solved. But reading the doc chapter on datagrid filters gave me no clues on how to sync a filtered datagrid with the assigned datalist.

    So again: can you help me here?

    Thank you!

  • Götz Krija

    Member
    January 27, 2026 at 8:19 am

    Hi Uwe,

    I do not think there is a built-in way to obtain a list with the currently displayed values. There is an enhancement request for this (ST/JS/2200), but it has not been implemented yet.

    However, it should be possible to retrieve the displayed values via JavaScript. I do not have much experience with JavaScript, but I managed to at least determine the number of rows currently displayed in the datagrid using the following code in a client-side executed method (maybe this is already sufficient for you):

    JavaScript:lFormName = $("#omnisobject1").attr("data-omnisclass");
    Calculate lID as con("#",lFormName,"_",$cinst.$objs.myDataGrid.$ident,"_grid")
    JavaScript:lGrid = $(lID).children(".slick-viewport").children(".grid-canvas");
    JavaScript:lRows = lGrid.children();
    JavaScript:for (var i=0; i<lRows.length; i++) {
    JavaScript:lRow = lGrid.children("[row=" + i +"]");
    JavaScript:}
    JavaScript: lDisplayedRows = i
    Do $cinst.$showmessage(con(lDisplayedRows,' are displayed'))

  • Uwe Smidt

    Member
    January 28, 2026 at 12:45 pm

    Hi Götz,

    Thank you for going the long way with JavaScript – I’ll try to integrate it into my code!

    And I hope for the enhancement request to be implemented soon- because the grid’s filter function is only half as useful – or rather unfinished, if it does not sync with the datalist attached to it.

    I really like the grid’s filter function, but as long as it doen’t sync it may be better to code your own filter functionality, so what you see (grid) is what you get (datalist). So I’ll look into filtering the datalist itself with $filter() and the like…

    Best regards
    Uwe

Log in to reply.