I updated another thread that I was working on here: How to make Repeating Group height dynamic to fit screen resolution?
This shows the full JS I used in the page header, without needing to create the HTML block, since I know the index of the Repeating Groups that I want to change the height of.
But although this works nicely for resizing, it has identified another bug/problem.
Go check it out - any suggestions welcome!