<!--
{
  "availability" : [
    "iOS: -",
    "iPadOS: -",
    "macCatalyst: -",
    "macOS: -",
    "tvOS: -",
    "visionOS: -",
    "watchOS: -"
  ],
  "documentType" : "symbol",
  "framework" : "os",
  "identifier" : "/documentation/os/OS_ACTIVITY_CURRENT",
  "metadataVersion" : "0.1.0",
  "role" : "Macro",
  "symbol" : {
    "kind" : "Macro",
    "modules" : [
      "os"
    ],
    "preciseIdentifier" : "c:@macro@OS_ACTIVITY_CURRENT"
  },
  "title" : "OS_ACTIVITY_CURRENT"
}
-->

# OS_ACTIVITY_CURRENT

A special value that selects the current activity, if there is one.

```
#define OS_ACTIVITY_CURRENT
```

## Discussion

When creating a new activity, pass this value as the activity’s parent to create the new activity with the current activity as its parent. If there is no active activity, the creation function returns the new activity as a top-level activity without a parent.

---

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)