---
title: SetName
framework: audiodriverkit
role: symbol
role_heading: Instance Method
path: audiodriverkit/iouseraudioobject/setname
---

# SetName

Sets the name of the object.

## Declaration

```occ
kern_return_t SetName(OSString *in_name);
```

## Parameters

- `in_name`: The name to set, as an doc://com.apple.documentation/documentation/DriverKit/OSString.

## Return Value

Return Value kIOReturnSuccess on success, or another value if an error occurs. For a list of error codes, see Error Codes.

## Discussion

Discussion If the change succeeds, the framework sends a notification to the host to update its object state. Setting the name synchronizes by using the work queue created by the object.

## See Also

### Working with Object Names

- [GetName](audiodriverkit/iouseraudioobject/getname.md)
