C# runtime raising App privileges

后端 未结 1 764
温柔的废话
温柔的废话 2021-02-01 11:12

I already tried every possible solution described in Stackoverflow.com, but I can\'t make an Application run as Administrator or prompt for Administrator privileges.

I t

1条回答
  •  清酒与你
    2021-02-01 11:54

    You specified "runas" verb in ProcessStartInfo. "Runas" is show as "Run as administrator". It is available for administrator accounts. For common user profile, only "runasuser" available, shell will open a login dialog to input administrator account name and password.

    You can check verbs of .exe file in HKEY_CLASSES_ROOT\exefile\shell

    0 讨论(0)
提交回复
热议问题