UserInclusionList.Remove Method (2007 System)
Deletes the inclusion list entry whose URI matches the parameter passed to the method.
Namespace: Microsoft.VisualStudio.Tools.Office.Runtime.Security
Assembly: Microsoft.VisualStudio.Tools.Office.Runtime.v9.0 (in Microsoft.VisualStudio.Tools.Office.Runtime.v9.0.dll)
Syntax
'Declaration
Public Shared Sub Remove ( _
uri As Uri _
)
'Usage
Dim uri As Uri
UserInclusionList.Remove(uri)
public static void Remove(
Uri uri
)
public:
static void Remove(
Uri^ uri
)
public static function Remove(
uri : Uri
)
Parameters
uri
Type: System.UriA Uri that specifies the location of the deployment manifest.
Exceptions
Exception | Condition |
---|---|
ArgumentNullException | uri is null. |
Remarks
This method deletes all valid and invalid entries that have the specified Uri.
If the Uri is not in the UserInclusionList, there is no error or return value.
If the UserInclusionList is empty, the UserInclusionList itself is deleted.
Examples
The following code example shows how to remove an AddInSecurityEntry from the UserInclusionList. This example requires an Imports (for Visual Basic) or using (for C#) statement for the Microsoft.VisualStudio.Tools.Office.Runtime.Security namespace at the top of your code file.
Dim solutionLocation As New _
Uri("http://DeploymentServer/MySolution/MySolution.vsto")
Try
UserInclusionList.Remove(solutionLocation)
Catch e As ArgumentNullException
Console.WriteLine(("Exception: " + e.Message))
End Try
Uri solutionLocation = new Uri("http://DeploymentServer/MySolution/MySolution.vsto");
try
{
UserInclusionList.Remove(solutionLocation);
}
catch (ArgumentNullException e)
{
Console.WriteLine("Exception: " + e.Message);
}
.NET Framework Security
- Full trust for the immediate caller. This member cannot be used by partially trusted code. For more information, see Using Libraries from Partially Trusted Code.
See Also
Reference
Microsoft.VisualStudio.Tools.Office.Runtime.Security Namespace