SecurityManager.SavePolicyLevel(PolicyLevel) Metod

Definition

Varning

This method is obsolete and will be removed in a future release of the .NET Framework. See http://go.microsoft.com/fwlink/?LinkID=155570 for more information.

Sparar en ändrad säkerhetsprincipnivå som läses in med LoadPolicyLevelFromFile(String, PolicyLevelType).

public:
 static void SavePolicyLevel(System::Security::Policy::PolicyLevel ^ level);
public static void SavePolicyLevel(System.Security.Policy.PolicyLevel level);
[System.Obsolete("This method is obsolete and will be removed in a future release of the .NET Framework. See http://go.microsoft.com/fwlink/?LinkID=155570 for more information.")]
public static void SavePolicyLevel(System.Security.Policy.PolicyLevel level);
static member SavePolicyLevel : System.Security.Policy.PolicyLevel -> unit
[<System.Obsolete("This method is obsolete and will be removed in a future release of the .NET Framework. See http://go.microsoft.com/fwlink/?LinkID=155570 for more information.")>]
static member SavePolicyLevel : System.Security.Policy.PolicyLevel -> unit
Public Shared Sub SavePolicyLevel (level As PolicyLevel)

Parametrar

level
PolicyLevel

Det principnivåobjekt som ska sparas.

Attribut

Undantag

Koden som anropar den här metoden har ControlPolicyinte .

Den här metoden använder kodåtkomstsäkerhetsprincipen (CAS), som är föråldrad i .NET Framework 4. Om du vill aktivera CAS-principen för kompatibilitet med tidigare versioner av .NET Framework använder du elementet <legacyCasPolicy>.

Kommentarer

PolicyLevel Sparas på samma plats som den lästes in från.

Gäller för