---
title: "init(name:)"
framework: appkit
role: symbol
role_heading: Initializer
path: "appkit/nspasteboard/init(name:)"
---

# init(name:)

Returns the pasteboard with the specified name.

## Declaration

```swift
init(name: NSPasteboard.Name)
```

## Parameters

- `name`: The name of the pasteboard. The names of standard pasteboards are given in Pasteboard Names.

## Return Value

Return Value The pasteboard associated with the given name, or a new NSPasteboard object if the application does not yet have a pasteboard object for the specified name.

## Discussion

Discussion Other names can be assigned to create private pasteboards for other purposes.

## See Also

### Creating and releasing a pasteboard

- [general](appkit/nspasteboard/general.md)
- [init(byFilteringData:ofType:)](appkit/nspasteboard/init(byfilteringdata:oftype:).md)
- [init(byFilteringFile:)](appkit/nspasteboard/init(byfilteringfile:).md)
- [init(byFilteringTypesInPasteboard:)](appkit/nspasteboard/init(byfilteringtypesinpasteboard:).md)
- [NSPasteboard.Name](appkit/nspasteboard/name-swift.struct.md)
- [withUniqueName()](appkit/nspasteboard/withuniquename().md)
- [releaseGlobally()](appkit/nspasteboard/releaseglobally().md)
