permissions - How to give my C# app administrative rights? manifest file -


I'm having some trouble with my C # app that uses win32_networkingadapterconfig The problem is that when I get a user I use the app which I do not give the administrator rights, then I can not use the shuffle functions in win32_networkingadapterconfig I have tried to "run as administrator", but there is no luck and I did not have this content in the TrustInfo part With a man Attempted to create an ifestfile:

  & lt; Security & gt; & Lt; ApplicationRequestMinimum & gt; & Lt; PermissionSat class = "System.Security.PermissionSet" version = "1" unrestricted = "true" id = "custom" same site = "site" /> & Lt; Default assembly request permission = "custom" /> & Lt; / ApplicationRequestMinimum & gt; & Lt; Requested privileges xmlns = "blur: schema-microsoft-com: asm.v3" & gt; & Lt; The requested exclusion level level = "requireAdministrator" uiAccess = "false" /> & Lt; / RequestedPrivileges & gt; & Lt; / Safety & gt;  

Clickon security setting has been set to full trust. What am i doing wrong

A "TrustInfo" hanging in your snippet is showing it like this:

  & lt ;? Xml version = "1.0" encoding = "UTF-8"? & Gt; & Lt; asmv1: Assembly manifestVersion = "1.0" xmlns = "Stigma: schemas-microsoft-com: asm.v1" xmlns: asmv1 = "urn: schemas-microsoft-com: asm.v1" xmlns: asmv2 = "urn: schemas -micosto -com: asm.v2 "xmlns: xsi =" http://www.w3.org/2001/XMLSchema-instance "& gt; & Lt; AssemblyIndentity version = "1.0.0.0" name = "MyApplication.app" /> & Lt; TrustInfo xmlns = "karash: schema-microsoft-com: asm.v2" & gt; & Lt; Security & gt; & Lt; Requested privileges xmlns = "blur: schema-microsoft-com: asm.v3" & gt; & Lt; The requested exclusion level level = "requireAdministrator" uiAccess = "false" /> & Lt; / RequestedPrivileges & gt; & Lt; / Safety & gt; & Lt; / TrustInfo & gt; & Lt; / Asmv1: assembly & gt;  

Comments

Popular posts from this blog

c# - How to capture HTTP packet with SharpPcap -

php - Multiple Select with Explode: only returns the word "Array" -

php - jQuery AJAX Post not working -