Currently, I use onEdit and it is being called when I change values in a cell or range of cells, or when deleting, inserting rows/columns.
function onEdit(e) {
Browser.msgBox('edit: ' + (e.range && e.range.getA1Notation()));
}
The onEdit function is not being called when hiding or showing a row through the UI.
Is there a way to get my script to be notified of a hide/show row event?
Update: I wrote a feature request for this in google-apps-script-issues: https://code.google.com/p/google-apps-script-issues/issues/detail?id=4670
Update: As per Kriggs answer, the installable trigger onChange can be used
Here's how that works.
However, on the e (event) object, there's no range property from which to see what row/range was hidden or shown. Also Krigg's suggested Row
method does not exist on e.source
.
How can we leverage onChange to also get the row number(s) hidden or shown?