<!--
{
  "availability" : [
    "macOS: 10.4.0 -"
  ],
  "documentType" : "symbol",
  "framework" : "SystemConfiguration",
  "identifier" : "/documentation/SystemConfiguration/SCNetworkSetAddService(_:_:)",
  "metadataVersion" : "0.1.0",
  "role" : "Function",
  "symbol" : {
    "kind" : "Function",
    "modules" : [
      "System Configuration"
    ],
    "preciseIdentifier" : "c:@F@SCNetworkSetAddService"
  },
  "title" : "SCNetworkSetAddService(_:_:)"
}
-->

# SCNetworkSetAddService(_:_:)

Adds the specified network service to the specified set.

```
func SCNetworkSetAddService(_ set: SCNetworkSet, _ service: SCNetworkService) -> Bool
```

## Parameters

`set`

The set (the complete configuration for a single location).

`service`

The service to add to the set.

## Return Value

`TRUE` if the service was added to the set; `FALSE` if the service was already present or an error occurred.

## Discussion

Prior to OS X v10.5, the Network Preferences pane did not support having a single service being a member of more than one set. Therefore, an error is returned if you attempt to add a service to more than one set on a pre-10.5 system.

---

Copyright &copy; 2026 Apple Inc. All rights reserved. | [Terms of Use](https://www.apple.com/legal/internet-services/terms/site.html) | [Privacy Policy](https://www.apple.com/privacy/privacy-policy)