none
Setting topmargin crashes word RRS feed

  • Question

  • This code crashes some of my users word...

    Globals.ThisAddIn.Application.ActiveDocument.PageSetup.TopMargin = Globals.ThisAddIn.Application.CentimetersToPoints(4)

    Any idea why?

    Wednesday, April 25, 2018 8:26 AM

All replies

  • Hello MOJO,

    Is there any error message for the issue? Why do you think this line code caused crashing? 

    You said some of your users word, is there any difference between their word version with other users?

    If you try to set the TopMargin with a number directly instead of CentimetersToPoints, will you get the error?

    Except TopMargin, have you tried other margin? Such as left, right and bottom?

    Best Regards,

    Terry


    MSDN Community Support
    Please remember to click "Mark as Answer" the responses that resolved your issue, and to click "Unmark as Answer" if not. This can be beneficial to other community members reading this thread. If you have any compliments or complaints to MSDN Support, feel free to contact MSDNFSF@microsoft.com.


    Thursday, April 26, 2018 4:50 AM