<?xml version="1.0" encoding="UTF-8"?><rss xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:atom="http://www.w3.org/2005/Atom" version="2.0" xmlns:cc="http://cyber.law.harvard.edu/rss/creativeCommonsRssModule.html">
    <channel>
        <title><![CDATA[Stories by Fred Derks on Medium]]></title>
        <description><![CDATA[Stories by Fred Derks on Medium]]></description>
        <link>https://medium.com/@fderks?source=rss-04c75d842881------2</link>
        <image>
            <url>https://cdn-images-1.medium.com/fit/c/150/150/1*e1wjYgJdGWtaX5SDNxww6A.jpeg</url>
            <title>Stories by Fred Derks on Medium</title>
            <link>https://medium.com/@fderks?source=rss-04c75d842881------2</link>
        </image>
        <generator>Medium</generator>
        <lastBuildDate>Thu, 19 Nov 2026 01:49:42 GMT</lastBuildDate>
        <atom:link href="https://medium.com/@fderks/feed" rel="self" type="application/rss+xml"/>
        <webMaster><![CDATA[yourfriends@medium.com]]></webMaster>
        <atom:link href="http://medium.superfeedr.com/" rel="hub"/>
        <item>
            <title><![CDATA[Mastering Dynamic Data in OutSystems with AG Grid — Part 2]]></title>
            <link>https://blog.product-league.com/mastering-dynamic-data-in-outsystems-with-ag-grid-part-2-51835bdd1d5e?source=rss-04c75d842881------2</link>
            <guid isPermaLink="false">https://medium.com/p/51835bdd1d5e</guid>
            <category><![CDATA[outsystems]]></category>
            <category><![CDATA[ag-grid]]></category>
            <category><![CDATA[front-end-development]]></category>
            <category><![CDATA[excel]]></category>
            <dc:creator><![CDATA[Fred Derks]]></dc:creator>
            <pubDate>Tue, 24 Feb 2026 13:10:56 GMT</pubDate>
            <atom:updated>2026-03-02T08:45:55.349Z</atom:updated>
            <content:encoded><![CDATA[<p>By Fred Derks</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/0*f7K6_zWvJ6Dy9tjc.jpeg" /></figure><p>In the <a href="https://medium.com/productleague/mastering-dynamic-data-in-outsystems-with-ag-grid-516a265598d6">first part of this series</a>, I explained <strong>why</strong> we chose AG Grid over DataGrid for a complex, Excel-like enterprise use case. In this follow-up, I’ll focus on the <strong>how</strong>: how we integrated AG Grid into an OutSystems Developer Cloud (ODC) application, how data flows into the grid, and how we progressively unlock more advanced behavior using the Grid API.</p><p>This isn’t meant to be a replacement for the official documentation. Instead, it reflects how I, an OutSystems developer, realistically approached the problem: starting with a simple, static grid and gradually turning it into something far more powerful.</p><h3>Adding a Grid to your screen</h3><p>AG Grid is a standalone JavaScript library, which means the first step is wrapping it in something that fits naturally into an OutSystems application. Luckily for you, I’ve already done that for you. That block is available as an <strong>AGGrid for ODC </strong><a href="https://www.outsystems.com/forge/component-overview/23062/aggrid-lib-odc">available from the ODC forge</a>.</p><p>This block is responsible for rendering the container, initializing the grid and exposing the GridObject once the grid is ready. This block also exposes a vast number of GridOptions in order to customize the grid upfront, without having to write any JavaScript.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/268/1*PJWiTPsPDjRmuKz3D_5apQ.png" /><figcaption>The AgGrid block, currently only available in static mode</figcaption></figure><p>Once the block is added to a screen, the initial setup is rather lightweight. You can fetch data using a regular aggregate or data action, serialize the result to JSON, and pass that JSON into the block. One important detail here is enabling <em>Serialize Default Values</em>. Without it, empty fields simply don’t exist in the resulting JavaScript object, which becomes a problem as soon as you allow editing.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/826/1*Ep_pry0nDEPQYNCFpWpK3g.png" /><figcaption>Serialize Default Values because otherwise there won’t be a JS object to store a value into when editing an empty field</figcaption></figure><p>At this stage, the grid is static. All columns are known upfront, and they’re defined through a GridOptions object that gets passed into the block. This includes column definitions, default behavior, and basic configuration like sorting or resizing. With just that in place, you already get a fast, virtualized grid that behaves well with large datasets.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/490/1*MLjrkrGw6y0CFLftPk8QGQ.png" /><figcaption>An example of a column being configured in GridOptions</figcaption></figure><p>Add a Column Definition for each field you want to have in the grid, point the field to the literal JSON field, which would be {Table}.[Column] if you are using an aggregate. You can then give the column a name, configure sorting, filters, an editable flag and much more. You can also set these values for the DefaultColumn if they are shared by more than one column.</p><p>Adding lots of columns this way can soon become a bit cumbersome and reordering them can be a hassle. I would suggest using listappend actions in the OnInitialize screen action.</p><h3>Updating the Grid by calling the API</h3><p>Where AG Grid really starts to shine is when you move beyond that basic setup. Most real applications don’t know everything upfront. Dropdown values arrive later, edit rules depend on user input, and styling often needs to react to state changes.</p><p>To support that, you need access to the Grid API.</p><p>When the AGGrid block initializes, it exposes a GridObject back to the screen. That object is effectively your entry point into everything AG Grid can do. From that moment on, you’re no longer “configuring a component”, you’re actively controlling a running grid.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/655/1*hTqa4jExm5p0VN-d_Q-W2w.png" /><figcaption>You can run customization code after the grid object is exposed andor after dropdown data is fetched, as is shown here.</figcaption></figure><p>In our implementation, we centralised all grid mutations into a single screen client action, which we call whenever something meaningful changes. That might be after fetching dropdown data, switching views, or recalculating values. Inside that action, a JavaScript node retrieves the current grid options, modifies what needs to change, and applies the updates through the API. The grid updates in place, without losing scroll position or selection.</p><h4>Customizing columns after initialization</h4><p>One of the first things we needed was dynamic dropdown editors. The grid itself doesn’t know which columns should be dropdowns until supporting data is loaded from the server.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/651/1*HsAEphogUCHDd2i534hmhg.png" /><figcaption>An example of an implementation of editable columns with dropdowns, in order to make sure this is ran after the dropdown values are ready, call this action in the OnAfterFetch.</figcaption></figure><p>Once that data arrives, we iterate over the column definitions and selectively enhance them. If a column represents a field like Category or Color, we attach AG Grid’s select cell editor and inject the dropdown values directly into the column definition. Nothing is rebuilt from scratch; we’re just enriching what already exists.</p><p>In order to merge the existing column definitions with the custom code you’ve written, you need to map the function to a copy you set aside, like so:</p><pre>let colDefs = GridAPI.getGridOption(&quot;columnDefs&quot;);<br>const updatedColDefs = colDefs.map(makeColumnEditable);<br>GridAPI.setGridOption(&quot;columnDefs&quot;, updatedColDefs);</pre><h4>Reacting to edited cells</h4><p>Cell editing is another area where AG Grid feels markedly different from DataGrid. Instead of binding logic to UI widgets, you work with events and metadata.</p><p>We attach an onCellValueChanged handler through the Grid API. When a user edits a cell, that handler checks whether the value actually changed, marks the cell as edited, and updates its styling immediately. We also trigger a screen client action and pass along the changed context.</p><pre>// Hook into the defaultColDef for all cells to track changes using cellEdited<br>let defaultColDef = GridAPI.getGridOption(&quot;defaultColDef&quot;);<br>defaultColDef.onCellValueChanged = cellEdited;<br>GridAPI.setGridOption(&quot;defaultColDef&quot;, defaultColDef);</pre><figure><img alt="" src="https://cdn-images-1.medium.com/max/656/1*d2Lkt6vs017OtlH8tU9_JA.png" /><figcaption>Some work is done before the OutSystems action is called, such as adding custom styling to mark a cell value that’s changed.</figcaption></figure><p>That context is rich. You get the previous value, the new value, the column, the row, and any custom metadata you’ve attached to the row object.</p><p>This makes it straightforward to collect edited values locally and submit only the modified data when the user decides to save, instead of reprocessing the entire dataset.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/699/1*428CUQEQ-ZrZo6UG99iqVA.png" /><figcaption>You have access to metadata as well as values from other columns in the onCellValueChanged event</figcaption></figure><h3>Under the Hood</h3><p>Up to this point, all interaction happens through the reusable <strong>AG Grid block</strong> that wraps the library inside OutSystems.</p><p>The block itself is intentionally minimal, to allow for full customization. A single div acts as the container. The AG Grid library is included as a required script. The grid instance is created only after the container is mounted, using AG Grid’s createGrid function, applying GridOptions and setting things like a theme and a license key (if used).</p><p>The resulting grid instance is stored and exposed so client actions can access the Grid API later. When input parameters change, updated row data is parsed and applied without recreating the grid, preserving scroll position, selection, and user context. Some grid options can be changed live, others require more care, but AG Grid is explicit about which is which.</p><p>Understanding this lifecycle becomes particularly useful when debugging timing or reactivity issues, since most unexpected behavior comes down to whether the grid has finished initializing before updates are applied.</p><h3>Concluding thoughts</h3><p>This component and the implementation that I’ve described should be a very solid foundation. With this structure in place, adding more advanced features becomes incremental. Dynamic columns, row selection with checkboxes, server-driven permissions, and more complex edit workflows all build on the same patterns.</p><p>The main takeaway from this implementation isn’t that AG Grid is better than DataGrid in some absolute sense. It’s that AG Grid gives you a level of control that makes Excel-style applications feasible inside OutSystems without fighting the platform.</p><h4>Important links</h4><p>Download the <a href="https://www.outsystems.com/forge/component-overview/23062/aggrid-lib-odc">AgGrid library for ODC here</a></p><p>Or have a look at the <a href="https://odc-dev.product-league.com/AGGridDemo/AGGridUserManual">user manual</a> which will guide you in more detail on how to implement your first AgGrid in ODC</p><p>Or download the <a href="https://www.outsystems.com/forge/component-documentation/23061/aggrid-demo-odc">demo application</a> we built, which serves as a great reference point for the actual implementation of all the examples I have described in this article.</p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=51835bdd1d5e" width="1" height="1" alt=""><hr><p><a href="https://blog.product-league.com/mastering-dynamic-data-in-outsystems-with-ag-grid-part-2-51835bdd1d5e">Mastering Dynamic Data in OutSystems with AG Grid — Part 2</a> was originally published in <a href="https://blog.product-league.com/">ProductLeague</a> on Medium, where people are continuing the conversation by highlighting and responding to this story.</p>]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[Mastering Dynamic Data in OutSystems with AG Grid]]></title>
            <link>https://blog.product-league.com/mastering-dynamic-data-in-outsystems-with-ag-grid-516a265598d6?source=rss-04c75d842881------2</link>
            <guid isPermaLink="false">https://medium.com/p/516a265598d6</guid>
            <category><![CDATA[ag-grid]]></category>
            <category><![CDATA[excel]]></category>
            <category><![CDATA[outsystems]]></category>
            <category><![CDATA[grid]]></category>
            <category><![CDATA[datagrid]]></category>
            <dc:creator><![CDATA[Fred Derks]]></dc:creator>
            <pubDate>Tue, 14 Jan 2025 09:12:52 GMT</pubDate>
            <atom:updated>2025-01-14T09:15:48.059Z</atom:updated>
            <content:encoded><![CDATA[<figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*wgR2NbS6ui5MLYg_Q_1Xqw.jpeg" /></figure><h3>Building a Better Grid for Complex Enterprise Data</h3><p>When building enterprise applications, displaying and managing large datasets is a common challenge. OutSystems offers several solutions for this, with DataGrid being the most commonly used component. However, there are alternatives like AG Grid that might better suit your needs depending on your requirements.</p><p>In a recent OutSystems Developer Cloud (<a href="https://www.outsystems.com/low-code-platform/developer-cloud/">ODC</a>) project, we faced the challenge of displaying large amounts of data in a user-friendly and manipulatable format. Our client heavily relied on Excel and an internal application with Excel-like features such as editable grids and column rearrangement. Our goal was to replace both the application and their reliance on Excel. To achieve this, we needed a robust grid component. In this two-part series, I’ll share our journey with grid components in OutSystems. In this first article, I’ll focus on comparing DataGrid and AG Grid, exploring their capabilities, limitations, and why we ultimately chose AG Grid for our specific use case. In the second part, we’ll dive deep into the technical implementation of AG Grid in ODC.</p><p>We initially started with OutSystems DataGrid, as it was the best-supported grid component on ODC. Our first implementations were straightforward: we built several screens with editable fields, including text editing, number editing, and dropdowns with conditional content. However, when we needed to implement dynamic columns, where both columns and rows were generated based on available data rather than predefined structures, we started hitting limitations.</p><p>The premise was as follows: users would select a period range, generating a column for each selected month. Rows were generated based on available categories. This setup differed from a pivot table, where pivoted columns remain static regardless of the data selection.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*Gf_mjpiSdIFdwv_Fexugwg.png" /><figcaption>Original application interface showing Excel-like grid layout</figcaption></figure><p>DataGrid struggled with this requirement. While generating columns and embedding them within a UI list was possible, customization proved challenging. The component’s built-in actions were limited, and its JavaScript API had sparse documentation. For example, pinning the ‘Total’ column to the right was unsupported. Additionally, managing editable fields required detailed context about the category and period, data that was difficult to associate with field changes in DataGrid.</p><p>At this point, we explored alternatives and discovered AG Grid. It stood out for supporting diverse use cases, offering extensive customization options, and providing robust documentation. The main downside was that there was no ODC component. We briefly looked at the OutSystems 11 <a href="https://www.outsystems.com/forge/list?q=Ag%20Grid&amp;t=&amp;o=most-popular&amp;tr=False&amp;oss=False&amp;c=%20&amp;a=&amp;v=&amp;hd=False&amp;tn=&amp;scat=forge">forge components</a> but quickly realized they were too limited and would not support our use case of dynamic columns with editable fields. Ultimately, we decided to implement AG Grid from scratch.</p><h3>Realizing Complex Use Cases with AG Grid</h3><p>This project demanded a very specific implementation of a grid that would not only replace their existing Excel-based workflow but enhance it. The following sections detail the key features we implemented, demonstrating how AG Grid’s capabilities enabled us to meet and exceed the original requirements.</p><p><strong>Freezing columns: </strong>The grid required frozen first and last columns. The first column displayed a list of categories, followed by columns for each period’s balance, and a final ‘Totals’ column summing all values for a category. As the number of period columns can vary depending on data selection, keeping the ‘Totals’ column always remains visible regardless of scrolling was essential. DataGrid couldn’t support this, but AG Grid made it <a href="https://www.ag-grid.com/javascript-data-grid/column-pinning/">trivial</a> to implement.</p><p><strong>Real-time grid updates</strong>: In our application, data is fetched asynchronously as users make changes to the selection using inputs on the same screen. When source data needs updating, we use AG Grid’s API to efficiently <a href="https://www.ag-grid.com/javascript-data-grid/data-update-row-data/">update specific cells or rows </a>without refreshing the entire grid. This maintains scroll position and selected cells while ensuring data consistency. The grid updates in real-time as users modify parameters or when backend calculations complete.</p><p><strong>Cell rendering</strong>: For readability, grid cells display rounded decimal values. However, if the user wishes to go more in depth, we implemented a tooltip showing the full unrounded value. With DataGrid, this would have required fetching tooltip data in a separate column. In AG Grid, this is managed by a <a href="https://www.ag-grid.com/javascript-data-grid/value-formatters/">cell renderer</a>, which retains the full values and just renders the cell with the specified formatting, such as rounding in this case.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/452/1*yKyM6tLgklHzfCJW_ygf_Q.png" /><figcaption>Rounded numbers with tooltips showing exact number</figcaption></figure><p>Additionally, rendering negative values using financial formatting (using brackets instead of minus) and conditional styling is also natively supported, <a href="https://www.ag-grid.com/javascript-data-grid/cell-styles/">well documented</a>, and context is never lost of the original value (with minus).</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/245/1*YFqxApwQSLSAfBWiF4iqjw.png" /><figcaption>Cell styling and formatting, retaining context about the original value</figcaption></figure><p><strong>Editable cells: </strong>Cells were made editable based on row, column, or nested parameter, allowing us to configure business rules about editability on the server side. Using the column API, you can <a href="https://www.ag-grid.com/javascript-data-grid/cell-editing/#conditional-editing">configure conditions and functions</a> that dynamically determine whether a cell is editable.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/525/1*IYzyE9yd_cI0JFg3VDd58w.png" /><figcaption>Cells that are editable are differentiated from uneditable cells by custom styling</figcaption></figure><p>Editable cells were <a href="https://www.ag-grid.com/javascript-data-grid/cell-styles/#cell-style">styled differently</a> to distinguish them, and unsaved changes were highlighted on the fly.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/213/1*dXijmEC_1zugcTB_t6jYOQ.png" /><figcaption>A look into the data structure for a given cell, it not only contains the value but also other useful parameters</figcaption></figure><p><a href="https://www.ag-grid.com/javascript-data-grid/tooltips/"><strong>Advanced tooltips</strong></a><strong>:</strong> In DataGrid, tooltips could only display values fetched with the initial dataset, which is impractical and unnecessary, especially with large datasets where relevant information does not have to be immediately visible. AG Grid allowed us to fetch tooltip data asynchronously at the moment when the tooltip is triggered, avoiding the need to pre-fetch all possible data. Although undocumented, we ultimately achieved this by exposing a client-side data-fetching action to JavaScript through the OnReady action.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/467/1*ri4aX-xGue5kHpQcLfB_1w.png" /><figcaption>Tooltips with asynchronous data fetching</figcaption></figure><p>To ensure a user-friendly overview of the export- and history data, the tooltip is formatted as a table. Styling tooltips requires writing some <a href="https://www.ag-grid.com/javascript-data-grid/tooltips/#custom-component">HTML</a>, but the flexibility this provides is worth the extra effort.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/945/1*sjdLkPbeNBRDYFkvzQAR6w.png" /><figcaption>Cell styling and tooltip styling</figcaption></figure><p><strong>Dynamic column headers:</strong> The first column header changes based on the selected view type. When users switch between Supply/Demand or Shipment views, we update the column definitions through AG Grid’s <a href="https://www.ag-grid.com/javascript-data-grid/column-properties/#reference-header-headerName">column API</a>. This includes both the header text and associated cell rendering logic. The change happens seamlessly without disrupting the grid’s state or user interactions.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/646/1*4THegkjMKgG6idiD87jFwA.gif" /><figcaption>Switching views not only updates the data but also the header of the first column</figcaption></figure><p><strong>Subcategory hierarchy</strong>: Subcategories in our grid require visual hierarchy through indentation. We implemented this by adding custom CSS classes through the column’s <a href="https://www.ag-grid.com/javascript-data-grid/column-properties/#reference-styling-cellStyle">cell style property</a>. The renderer checks each row’s category type and applies appropriate styling. This creates a clear visual distinction between main categories and their subcategories, making the data hierarchy immediately apparent to users. Some examples can be seen above.</p><p><strong>Interactive charting</strong>: We implemented an interactive charting feature that visualizes data from selected grid cells. As users select cells, the corresponding chart updates dynamically using AG Grid’s <a href="https://www.ag-grid.com/javascript-data-grid/integrated-charts-range-chart/">range chart feature</a>. This provides immediate visual feedback and allows users to analyze trends across different periods and categories. The charts maintain context with the grid selection, enabling users to quickly switch between different data views.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*mfdMAh3U87kzBgu5NIhDbg.png" /><figcaption>A chart generated based on the selected cell range</figcaption></figure><h3>DataGrid vs AG Grid</h3><p>Both components are excellent options for displaying and managing large sets of data. Each comes with its advantages and limitations but both provide an easy way to implement sorting, filtering, grouping, pivoting, and cell editing. During our implementation, we discovered key differences in their capabilities that influenced our choice.</p><h4>DataGrid</h4><p>DataGrid is specifically built for OutSystems, being an adaptation of <a href="https://developer.mescius.com/wijmo/flexgrid-javascript-data-grid">Wijmo’s FlexGrid</a>. Therefore, to OutSystems developers, it is user-friendly and requires minimal coding. You can drag and drop the component to the screen, bind it to a datasource, and configure sorting and pagination, all within Service Studio. No need to write JavaScript or figure out custom integrations, it just works with other OutSystems components out of the box. Want to reference a data action or structure? Just pick it from the dropdown and you’re done. In casual use cases there is usually no need for custom integrations.</p><p>However, this ease of use comes at a cost. When we needed to implement complex features like custom filtering based on multiple fields, we ran into DataGrid’s limitations. The documentation assumes basic use cases, which was fine initially, but as requirements grew more complex, we found ourselves unable to implement certain features. Something as seemingly straightforward as pinning the ‘Total’ column to the right proved impossible. The JavaScript API documentation is sparse, leaving developers to figure things out through trial and error.</p><h4>AG Grid</h4><p>AG Grid takes a fundamentally different approach. Its extensive customization options allowed us to handle complex scenarios elegantly. Need a custom cell renderer that shows formatted numbers with tooltips? There’s a clear way to do that. Want to implement advanced filtering logic? The documentation not only shows you how, but provides multiple approaches with pros and cons. The performance holds up remarkably well even with thousands of rows thanks to virtual scrolling and other optimizations. When we did run into issues, the combination of detailed documentation and active community meant solutions were readily available.</p><p>The tradeoff comes in initial setup time and complexity. Developers need to be comfortable with JavaScript and invest time in understanding the library’s patterns. The free version covers many features, but some advanced ones like enhanced filtering, integrated charts, and Excel export require a paid license (though we found a workable alternative for the latter). For example, implementing our dynamic columns with editable fields required understanding AG Grid’s column API, cell renderers, and event system. This level of control simply wasn’t possible in DataGrid, where we were limited to basic cell templates and predefined formatting options.</p><h3>Choosing the Right Grid for Your OutSystems Project</h3><p>In our case, AG Grid’s flexibility made it the right choice despite the additional setup complexity. The rich customization options and robust documentation helped us deliver exactly what users needed, while DataGrid’s limitations would have forced compromises in functionality. That said, for simpler use cases where basic grid functionality suffices, DataGrid’s ease of use makes it a compelling option.</p><p>Stay tuned for Part 2 of this blog series where we’ll dive into the technical implementation details of AG Grid in OutSystems, including setup, configuration, and advanced features.</p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=516a265598d6" width="1" height="1" alt=""><hr><p><a href="https://blog.product-league.com/mastering-dynamic-data-in-outsystems-with-ag-grid-516a265598d6">Mastering Dynamic Data in OutSystems with AG Grid</a> was originally published in <a href="https://blog.product-league.com/">ProductLeague</a> on Medium, where people are continuing the conversation by highlighting and responding to this story.</p>]]></content:encoded>
        </item>
    </channel>
</rss>