<!--
{
  "availability" : [
    "macOS: 10.0.0 - 10.15.0"
  ],
  "documentType" : "symbol",
  "framework" : "CoreFoundation",
  "identifier" : "/documentation/CoreFoundation/CFBundleOpenBundleResourceFiles(_:_:_:)",
  "metadataVersion" : "0.1.0",
  "role" : "Function",
  "symbol" : {
    "kind" : "Function",
    "modules" : [
      "Core Foundation"
    ],
    "preciseIdentifier" : "c:@F@CFBundleOpenBundleResourceFiles"
  },
  "title" : "CFBundleOpenBundleResourceFiles(_:_:_:)"
}
-->

# CFBundleOpenBundleResourceFiles(_:_:_:)

Opens the non-localized and localized resource files (if any) for a bundle in separate resource maps.

```
func CFBundleOpenBundleResourceFiles(_ bundle: CFBundle!, _ refNum: UnsafeMutablePointer<CFBundleRefNum>!, _ localizedRefNum: UnsafeMutablePointer<CFBundleRefNum>!) -> Int32
```

## Parameters

`bundle`

The bundle whose resource map you want to open.

`refNum`

On return, the reference number of the non-localized resource map.

`localizedRefNum`

On return, the reference number of the localized resource map.

## Return Value

An error code. The function returns `0` (`noErr`) if successful. If the bundle contains more than one resource file, the function returns an error code only if none was opened. The most common error is `resFNotFound`, but the function may also pass through other errors returned from the Resource Manager.

## Discussion

---

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)