This seems to be the correct behavior. I was able to replicate the issue. However, if you look into the SetPrintAttribute (ATTR_EJECT_AFTER, 0), it says:
Specifies whether to eject the paper from the printer after the next call to a printing function. If ATTR_EJECT_AFTER is set to zero, outputs are printed on the same page until ATTR_EJECT_AFTER is set to one.
So it won't print anything until you specify the end of the page. It won't print until that call where you set it back to 1. I made a very small sample program that shows how to use it properly. If you experience problems on your machine, please post back. Thanks.