请教高手:提高管理员权限遇到的问题
目前程序已经实现的部分:
1. 利用 AdjustTokenPrivileges 方法提高权限,在 win7 下返回 ERROR_NOT_ALL_ASSIGNED;
2. 为了解决 1 中的问题,采用 manifest 文件来实现。编译通过,出现 warning 问题:
manifest authoring warning 81010002: Unrecognized Element "requestedPrivileges" in namespace "urn:schemas-microsoft-com:asm.v3"
看到网上很多帖子说这个不影响程序在 win7 上的运行。但我的依然不可以。。。
3. 项目是需要编译 dll 文件的。
有一哥们说 manifest 只对 exe 文件起作用,dll 可能不行。。。比较晕。。
还请高手解答。。