<!--
{
  "availability" : [
    "iOS: 14.0.0 - 27.0.0",
    "iPadOS: 14.0.0 - 27.0.0",
    "macCatalyst: 14.0.0 - 27.0.0",
    "macOS: 11.0.0 - 27.0.0",
    "visionOS: 1.0.0 - 27.0.0"
  ],
  "documentType" : "symbol",
  "framework" : "MetricKit",
  "identifier" : "/documentation/MetricKit/MXBackgroundExitData/cumulativeSuspendedWithLockedFileExitCount",
  "metadataVersion" : "0.1.0",
  "role" : "Instance Property",
  "symbol" : {
    "kind" : "Instance Property",
    "modules" : [
      "MetricKit"
    ],
    "preciseIdentifier" : "c:objc(cs)MXBackgroundExitData(py)cumulativeSuspendedWithLockedFileExitCount"
  },
  "title" : "cumulativeSuspendedWithLockedFileExitCount"
}
-->

# cumulativeSuspendedWithLockedFileExitCount

The number of times the system terminated the app from the background while being suspended and having file locks.

```
var cumulativeSuspendedWithLockedFileExitCount: Int { get }
```

## Discussion

A common cause for this kind of exit is writing to an SQLite database as the system is suspending the app. For information on what to do with open files and databases when transitioning to the background, see <doc://com.apple.documentation/documentation/UIKit/preparing-your-ui-to-run-in-the-background>.

---

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)