<!--
{
  "availability" : [
    "iOS: -",
    "iPadOS: -",
    "macCatalyst: -",
    "macOS: -",
    "tvOS: -",
    "visionOS: -",
    "watchOS: -"
  ],
  "documentType" : "symbol",
  "framework" : "CoreFoundation",
  "identifier" : "/documentation/CoreFoundation/CFDateFormatterSetProperty(_:_:_:)",
  "metadataVersion" : "0.1.0",
  "role" : "Function",
  "symbol" : {
    "kind" : "Function",
    "modules" : [
      "Core Foundation"
    ],
    "preciseIdentifier" : "c:@F@CFDateFormatterSetProperty"
  },
  "title" : "CFDateFormatterSetProperty(_:_:_:)"
}
-->

# CFDateFormatterSetProperty(_:_:_:)

Sets a date formatter property using a key-value pair.

```
func CFDateFormatterSetProperty(_ formatter: CFDateFormatter!, _ key: CFString!, _ value: CFTypeRef!)
```

## Parameters

`formatter`

The date formatter to modify.

`key`

The name of the property to set. See [Date Formatter Property Keys](/documentation/CoreFoundation/date-formatter-property-keys) for a description of possible values for this parameter.

`value`

The value for `key`. This should be a CFType object corresponding to the specified key.

## 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)