We have checked your code and it's working with the demo project (activated with a premium license), check the screenshot:
The method returns -10 in 3 cases:
--path is null or invalid
--premium license is not actived.
--can't create/open file for path, if occoured.
The path is aparently valid, so make sure that the premium license is activated correctly, and that there is no write-premission problem.
Creation of new document returns error -10
3 years 11 months ago #8756
I'm doing the following to activate the Premium license:
Is all right?