2D, 3D, game, games, online game, game development, game engine, programming, OpenGL, Open AI, math, graphics, design, graphic, graphics, game development, game engine, programming, web development, web art, web graphic, arts, tutorial, tutorials,
miercuri, 12 noiembrie 2025
Google Apps Script : how to filter data by the value in a cell and reset the filter.
If you look at this blog, you will find examples of the results of running GAScript scripts in Excel. Today, I will show you how to filter the entire table based on a value from a cell and how to reset it to the original result without filtering.
function reseteazaFiltrarea() {
const sheet = SpreadsheetApp.getActiveSheet();
const ultimaLinie = sheet.getLastRow();
sheet.showRows(1, ultimaLinie);
SpreadsheetApp.getUi().alert("Toate rândurile au fost afișate.");
}
function filtreazaRanduriDupaCelulaSelectata() {
const sheet = SpreadsheetApp.getActiveSheet();
const cell = sheet.getActiveCell();
const valoare = cell.getValue();
const coloanaDeFiltrare = cell.getColumn();
const ultimaLinie = sheet.getLastRow();
for (let i = 1; i <= ultimaLinie; i++) {
const valoareRand = sheet.getRange(i, coloanaDeFiltrare).getValue();
sheet.showRows(i); // asigură-te că rândul e vizibil
if (valoareRand !== valoare && i !== cell.getRow()) {
sheet.hideRows(i);
}
}
SpreadsheetApp.getUi().alert(`Filtrare aplicată pentru: ${valoare}`);
}
Posted by
Cătălin George Feștilă
Labels:
2025,
google,
Google Apps Script,
open source,
source code,
tutorial,
tutorials
News : How religion, politics, and housing shape society - design by ChrWr.
... another good design on graphics ! one video from the Chris Were .
News : ... another programming youtube channel by rajcodes .
... programming with rajcodes - the official youtube channel.
Let's see one video from this youtube channel named “How C Code Becomes a Binary: A Raspberry Pi Walkthrough”.
marți, 11 noiembrie 2025
Abonați-vă la:
Comentarii (Atom)