Carbon


URLGetFileInfo

Header: URLAccess.h Carbon status: Supported

Obtains the file type and creator of a file.

OSStatus URLGetFileInfo (
    StringPtr fName, 
    OSType *fType, 
    OSType *fCreator
);
Parameter descriptions
fName

A pointer to a Pascal string representing the name of the file for which you want information.

fType

On return, a pointer to the file type code of the specified filename.

fCreator

On return, a pointer to the file creator code of the specified filename.

function result

A result code.

DISCUSSION

The URLGetFileInfo function obtains the file type and creator codes for a specified filename. The type and creator codes are determined by the Internet configuration mapping table and are based on the filename extension. For example, if you pass the filename “jane.txt”, URLGetFileInfo will return 'TEXT' in the type parameter and 'ttxt' in the creator parameter.

AVAILABILITY

Supported in Carbon. Available in Carbon 1.0.2 and later when running Mac OS 8.1 or later.


© 2000 Apple Computer, Inc. (Last Updated 7/17/2000)