---
title: "remoteObjectProxyWithErrorHandler(_:)"
framework: foundation
role: symbol
role_heading: Instance Method
path: "foundation/nsxpcconnection/remoteobjectproxywitherrorhandler(_:)"
---

# remoteObjectProxyWithErrorHandler(_:)

Returns a proxy for the remote object (that is, the object exported from the other side of this connection) with the specified error handler.

## Declaration

```swift
func remoteObjectProxyWithErrorHandler(_ handler: @escaping (any Error) -> Void) -> Any
```

## Discussion

Discussion See descriptions in NSXPCProxyCreating for more details.

## See Also

### Working with proxy objects

- [synchronousRemoteObjectProxyWithErrorHandler(_:)](foundation/nsxpcconnection/synchronousremoteobjectproxywitherrorhandler(_:).md)
