Page Setup

  • Thread starter Thread starter Alexander Bushan
  • Start date Start date
A

Alexander Bushan

Just change this line
sRange = "A1:H" & iXrow
to:
Set sRange = objWS.Range("A1:H" & iXrow)
 
From VBA's immediate window:

?xlLandscape
2

objWS.PageSetup.Orientation = xlLandscape
would become
objWS.PageSetup.Orientation = 2

(What was iXrow equal to when you ran it the first time?)
 
Back
Top