If I use the Shell Protection with .NET Encryption, I get Unknown error 0x80131604.

Please check if your program uses the Assembly class. This particular class can cause a conflict with the technique we use to encrypt .NET assembly. If this is the case, please try to avoid using this class. Then, try to use ElecKey to protect your program again.