Can you programatically set the page orientation of the default printer ?

I have tried: printer.orientation = 2

BUT it always stays in the default port. mode