You should be able to achieve this simply by specifying a little bit of script for each of the subform's prePrint and postPrint events in the Script Editor.
In each subform's prePrint event, use the following FormCalc script:
$.fillColor = "255,255,255";
This will set each subform's fill (background) color to white when the user chooses the print the form.
Then set each subform's postPrint event to the following FormCalc script:
$.fillColor = "255,255,0";
This will set the subform's fill (background) color to yellow. Use the RGB values for red (255,0,0) and green (0,255,0) for their respective subforms.
I've attached a sample form which contains a subform with a yellow background color. When you press the print button, the subform's background color is changed to white. When the print dialog is dismissed (with either OK or Cancel), the subform's background color is restored to its original yellow.
Stefan
Adobe Systems