Dear list, I just inserted my *second* ERT (woohoo!) and I found a place you should NOT put it!
I inserted it at the start of a section heading, this heading had a page break associated above it. The section number disappeared from the heading whenever the ERT was unfolded. The LaTeX run was very upset with me for doing that as well. Once I removed it, I had exceeded my TeX capacity (apparently) and its stack was reported as set to 500. It wanted me to resize it. Can't get rid of the error! WTF? Have fun, Darren