I need to change page margin from script.
I write this to change margins adding a new page but don't work.
#-------------------------------------------------------------------
def isodd(self,n): return 1 == n % 2;
#-------------------------------------------------------------------
def appendPage(self) :
messageBox("Debug","AppendingNewPage")
newPage(-1)
if not self.isodd(currentPage()):
messageBox("Debug","IS Even!!!")
pgTop,pgLeft,pgRight,pgBottom=getPageMargins()
# Now swap left and right margins
setMargins(pgRight,pgLeft, pgTop,pgBottom)
#-------------------------------------------------------------------