I have been having the same problems with screen protection too - the method you provide to ensure that the DWM is switched on does not apply to anything above window 8. On windows 10 I have tried HKEY_CURRENT_USER\Software\Microsoft\Windows\DWM and then accessed the compositon option which was set at 1 - I changed this to 0 hoping that it would turn it on.
However, it had no effect - I have the option to close down the app if screen protection cannot be activated, however, if I switch this off the application runs fine - so, can I assume by this that the screen protection is definitely not activated?
Also, I am trying to produce a trial version of my application and this does not work.
Thanks for your help