Adds a specified permission to the System.Security.PermissionSet.
The union of the permission added and any permission of the same type that already exists in the System.Security.PermissionSet.
Type Reason ArgumentException perm is not a System.Security.IPermission object.
If a permission of the same type as the added permission already exists in the System.Security.PermissionSet, the new permission is the union of the existing permission object and the specified permission object. For example, if a permission that implements System.Security.Permissions.IUnrestrictedPermission is added to an System.Security.Permissions.PermissionState.Unrestricted System.Security.PermissionSet, the resulting union is the original Unrestricted System.Security.PermissionSet.