---
title: "UTCreateStringForOSType(_:)"
framework: coreservices
role: symbol
role_heading: Function
path: coreservices/1442804-utcreatestringforostype
---

# UTCreateStringForOSType(_:)

Encodes an OSType into a string suitable for use as a tag argument.

## Declaration

```swift
func UTCreateStringForOSType(_ inOSType: OSType) -> Unmanaged<CFString>
```

## Parameters

- `inOSType`: The OSType to convert.

## Return Value

Return Value A string that encodes the OSType.

## Discussion

Discussion The UTI functions assume that all alternate identifier tags can be represented as Core Foundation strings. OSTypes are integer-based rather than string-based, so to pass an OSType into a UTI function, you must call this function to convert it to a string.

## See Also

### Related Documentation

- [UTGetOSTypeFromString(_:)](coreservices/1450472-utgetostypefromstring.md)
