CodeConnectAccess.CreateAnySchemeAccess(Int32) Method
Important
Some information relates to prerelease product that may be substantially modified before it’s released. Microsoft makes no warranties, express or implied, with respect to the information provided here.
Returns a CodeConnectAccess instance that represents access to the specified port using any scheme.
public:
static System::Security::Policy::CodeConnectAccess ^ CreateAnySchemeAccess(int allowPort);
public static System.Security.Policy.CodeConnectAccess CreateAnySchemeAccess(int allowPort);
static member CreateAnySchemeAccess : int -> System.Security.Policy.CodeConnectAccess
Public Shared Function CreateAnySchemeAccess (allowPort As Integer) As CodeConnectAccess
- allowPort
- Int32
The port represented by the returned instance.
A CodeConnectAccess instance for the specified port.
The following code example demonstrates calling this method. For an example that demonstrates using CodeConnectAccess objects to create a code group and adding the code group to a policy level, see the CodeConnectAccess class overview.
static CodeConnectAccess^ CreateAnySchemeOriginPortAccess()
{
return CodeConnectAccess::CreateAnySchemeAccess
(CodeConnectAccess::OriginPort);
}
public static CodeConnectAccess CreateAnySchemeOriginPortAccess()
{
return CodeConnectAccess.CreateAnySchemeAccess(CodeConnectAccess.OriginPort);
}
The CodeConnectAccess instance returned by this method uses the scheme wildcard value AnyScheme ("*") to represent the scheme.
Product | Versions |
---|---|
.NET | 8 (package-provided), 9 (package-provided), 10 (package-provided) |
.NET Framework | 2.0, 3.0, 3.5, 4.0, 4.5, 4.5.1, 4.5.2, 4.6, 4.6.1, 4.6.2, 4.7, 4.7.1, 4.7.2, 4.8, 4.8.1 |
.NET Standard | 2.0 (package-provided) |
Windows Desktop | 3.0, 3.1, 5, 6, 7, 8, 9, 10 |
.NET feedback
.NET is an open source project. Select a link to provide feedback: