INetFwRule::put_LocalPorts method (netfw.h)
Specifies the list of local ports for this rule.
This property is read/write.
Syntax
HRESULT put_LocalPorts(
BSTR portNumbers
);
Parameters
portNumbers
Return value
None
Remarks
This property is optional.
Also see the restrictions on changing properties described in the Remarks section of the INetFwRule interface page.
The Protocol property must be set before the LocalPorts property or an error will be returned.
Requirements
Requirement | Value |
---|---|
Minimum supported client | Windows Vista [desktop apps only] |
Minimum supported server | Windows Server 2008 [desktop apps only] |
Target Platform | Windows |
Header | netfw.h |
DLL | FirewallAPI.dll |