---
title: "loadFileRepresentation(forTypeIdentifier:completionHandler:)"
framework: foundation
role: symbol
role_heading: Instance Method
path: "foundation/nsitemprovider/loadfilerepresentation(fortypeidentifier:completionhandler:)"
---

# loadFileRepresentation(forTypeIdentifier:completionHandler:)

Asynchronously writes a copy of the provided, typed data to a temporary file, returning a progress object.

## Declaration

```swift
func loadFileRepresentation(forTypeIdentifier typeIdentifier: String, completionHandler: @escaping @Sendable (URL?, (any Error)?) -> Void) -> Progress
```

## Discussion

Discussion This method writes a copy of the file’s data to a temporary file, which the system deletes when the completion handler returns.

## See Also

### Loading the provider’s contents

- [loadItem(forTypeIdentifier:options:completionHandler:)](foundation/nsitemprovider/loaditem(fortypeidentifier:options:completionhandler:).md)
- [loadDataRepresentation(forTypeIdentifier:completionHandler:)](foundation/nsitemprovider/loaddatarepresentation(fortypeidentifier:completionhandler:).md)
- [loadDataRepresentation(for:completionHandler:)](foundation/nsitemprovider/loaddatarepresentation(for:completionhandler:).md)
- [loadFileRepresentation(for:openInPlace:completionHandler:)](foundation/nsitemprovider/loadfilerepresentation(for:openinplace:completionhandler:).md)
- [loadInPlaceFileRepresentation(forTypeIdentifier:completionHandler:)](foundation/nsitemprovider/loadinplacefilerepresentation(fortypeidentifier:completionhandler:).md)
- [loadObject(ofClass:completionHandler:)](foundation/nsitemprovider/loadobject(ofclass:completionhandler:)-8ak5d.md)
- [loadObject(ofClass:completionHandler:)](foundation/nsitemprovider/loadobject(ofclass:completionhandler:)-6pysm.md)
- [loadTransferable(type:completionHandler:)](foundation/nsitemprovider/loadtransferable(type:completionhandler:).md)
