There were similar post a few years ago, maybe this will help:
https://forum.mendix.com/link/questions/87506 which redirects to:
https://appstore.home.mendix.com/link/app/2026/
and https://forum.mendix.com/link/questions/8539 which uses a java action
And you should check this stackoverflow question:
https://stackoverflow.com/questions/3022376/how-can-i-convert-a-word-document-to-pdf
In short, it is doable but you will never get it pixel perfect unless you are willing to pay for API's that do it for you.
Regards,
Ronald