The method getPageOrientation is used for obtaining the orientation of a report page. You should call this method after calling the runReport method. The returned value is an int value, which can be LANDSCAPE or PORTRAIT. If the returned value is -1, it makes no sense, and you may have called it before calling runReport method, which is wrong.