【问题标题】:SRSetRestorePoint does not create a restore pointSRSetRestorePoint 不创建还原点
【发布时间】:2023-01-16 16:58:19
【问题描述】:

我正在尝试使用 C API 函数 SRSetRestorePoint 在 Windows 上使用官方示例创建还原点:

https://learn.microsoft.com/en-us/windows/win32/sr/using-system-restore#example-1-create-a-restore-point

它编译得很好,也一直运行到调用SRSetRestorePoint,在我的例子中返回 false。

SMgrStatus.nStatus 的值为 5,未记录为状态。我正在检查这里的每个状态代码:

https://learn.microsoft.com/en-us/windows/win32/api/srrestoreptapi/ns-srrestoreptapi-statemgrstatus#remarks

我在 Windows 10 上,一切都是最新的。应该为创建还原点启用的每个服务都已启用,其他程序(如 shut up 10)能够创建还原点。在朋友的 PC 上,我(或 Microsoft 人员)编写的小程序也会发生同样的事情。

我也不可能使用 wmic 创建还原点。 (见https://www.winhelponline.com/blog/create-system-restore-point-script-windows-10-8-7-vista-xp/

至少 rstrui.exe 没有显示任何新的还原点。

有没有人也遇到过这个问题或对此有解决方案?

提前致谢,如果您需要我的系统的更多信息,请告诉我。

【问题讨论】:

    标签: c windows restore-points


    【解决方案1】:

    要创建还原点,您必须具有管理员权限。

    【讨论】:

      猜你喜欢
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      • 2012-05-31
      • 2012-10-27
      • 1970-01-01
      相关资源
      最近更新 更多