Grid PDF export aborts, EOutOfMemory

Hi, 


The PDF is kept in memory and is then written once to a file. We'll investigate if we can flush between pages to improve memory usage