Creating a new directory from C# with Encrypting File System switched on

前端 未结 3 915
刺人心
刺人心 2021-01-05 21:15

Has anyone created a new directory from C# with Encrypting File System switched on?

Additionally any information on doing this from an install would be helpful too.<

3条回答
  •  再見小時候
    2021-01-05 21:35

    The managed methods File.Encrypt() and FileInfo.Encrypt() both simply call the native EncryptFile() that is shown in the other answer.

    So, no need to go to all the trouble to declare the p/invoke API. Just use the built-in methods.

提交回复
热议问题