Data grid 2: Select all across pages

0
Hi everyone,I’ve been wrestling with a frustrating UI/UX issue regarding Data Grid 2 and hoping to see if anyone has found a clean native solution, or if my workaround is the accepted best practice.The Scenario: I have a Data Grid 2 displaying a large dataset (e.g., 400+ rows) with pagination set to 100 rows per page. I am using custom SCSS to pin the first few columns and the header to the top/left (position: sticky).I want to allow users to perform a bulk update on all 400+ filtered rows, so I enabled the native "Select all" across pages feature in the grid's Behavior tab.The Problem: When the user clicks the master checkbox, Mendix dynamically injects a text banner (e.g., "Select all 468 rows in the data source") directly into the DOM of that tiny checkbox header cell.Because of how Mendix uses Flexbox/Grid for the headers, this long text forces the checkbox column to stretch massively horizontally. This pushes all the adjacent sticky columns (like Reference Designator, etc.) to the right, completely breaking alignment with the actual data rows below them.
asked
4 answers
0

It must be your custom SCSS forcing this behaviour. Standard Data Grid 2 makes place for the message below the headers.


answered
0

The problem was in core source code of "Select All" checkbox. In the oldest versions of Data Widgets module it was written with little bug. To fix this, just download the latest compatible version and update all widgets in the errors tab. Then it becomes like this:

answered
0

The Select all ### rows in the data source message shows up, but when I click it, only the records on that page are selected. Recognize that problem?

answered
0

Hi Zholdas,


This looks like a combination of the Data Grid 2 Select All implementation and the custom sticky-column CSS.

I found a similar issue reported in the Mendix Community. The suggested fix was to update to the latest compatible Data Widgets version, as older versions had an issue in the Select All checkbox implementation.


I would suggest the following:

  1. Update Data Widgets: Install the latest version compatible with your Mendix Studio Pro version, and update the widgets where required. Test the Select All behavior before applying any additional CSS changes.
  2. Check the custom sticky-column CSS: Temporarily disable your custom position: sticky styles and test the grid again. If the alignment issue disappears, review the sticky columns' widths, positioning, and header layout.
  3. Avoid forcing the checkbox column width blindly: The Select All message is rendered dynamically, so hardcoding widths or adding !important overrides may hide the message or introduce other alignment issues.
  4. If the issue persists: Reproduce it with the latest compatible Data Widgets version and without custom CSS. If the standard grid still stretches the checkbox column, report it to Mendix with the widget version and a minimal test case.

One additional point: if your actual requirement is to bulk-update all 400+ filtered records, make sure the operation targets the complete filtered dataset. The grid's visible-row selection and the application's bulk-processing logic are separate concerns.

References:


Hope this helps.

answered