Function

NSHomeDirectoryForUser

Returns the path to a given user’s home directory.

Declaration

NSString * NSHomeDirectoryForUser(NSString *userName);

Parameters

userName

The name of a user.

Return Value

The path to the home directory for the user specified by userName.

Discussion

For more information on file system utilities, see Low-Level File Management Programming Topics.

See Also

Accessing User Directories

homeDirectoryForCurrentUser

The home directory for the current user.

NSHomeDirectory

Returns the path to either the user’s or application’s home directory, depending on the platform.

NSUserName

Returns the logon name of the current user.

NSFullUserName

Returns a string containing the full name of the current user.

- homeDirectoryForUser:

Returns the home directory for the specified user.

temporaryDirectory

The temporary directory for the current user.

NSTemporaryDirectory

Returns the path of the temporary directory for the current user.