Change the right tab of ruler

image.png (46.7 KB)
Is there any method to change the right tab of the ruler to right?

@lkf77081 It looks like you need to change right margin. You can do this using PageSetup.RightMargin property.

i had tried with using [PageSetup.RightMargin] before ,the result is not what i want.

@lkf77081 Could you please attach your input document and expected output? We will check the issue and provide you more information.