Get FileSystem Restrictions

后端 未结 2 1568
渐次进展
渐次进展 2021-02-06 05:16

I would like to code a function that tells me if it\'s possible to WRITE a file/folder to a specific path or not. I would like to do that WITHOUT actually writing any file(s) to

2条回答
  •  臣服心动
    2021-02-06 05:50

    You can use GetFileSecurity() and AccessCheck() functions. Read the Aaron Ballman's article on How to Check Access Rights. He provided the CanAccessFolder() function to do what you asked.

提交回复
热议问题