Share via


SecurityManager.SavePolicyLevel(PolicyLevel) Méthode

Définition

Attention

Cette API est à présent déconseillée.

Attention

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.

Enregistre un niveau de stratégie de sécurité modifié chargé avec LoadPolicyLevelFromFile(String, PolicyLevelType).

public:
 static void SavePolicyLevel(System::Security::Policy::PolicyLevel ^ level);
[System.Obsolete]
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);
[<System.Obsolete>]
static member SavePolicyLevel : System.Security.Policy.PolicyLevel -> unit
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)

Paramètres

level
PolicyLevel

Objet de niveau de stratégie à enregistrer.

Attributs

Exceptions

Le code qui appelle cette méthode ne dispose pas de ControlPolicy.

Cette méthode utilise la stratégie de sécurité d’accès du code (CAS), qui est obsolète dans .NET Framework 4. Pour activer la stratégie de sécurité d’accès du code (CAS) pour la compatibilité avec les versions antérieures de .NET Framework, utilisez l’élément <legacyCasPolicy>.

Remarques

le PolicyLevel est enregistré à l’emplacement à partir duquel il a été chargé.

S’applique à