Movatterモバイル変換


[0]ホーム

URL:


Legacy Documentclose button

Important:The information in this document is obsolete and should not be used for new development.

PreviousBook ContentsBook IndexNext


HOpenRF

You can use theHOpenRF function to open the resource fork of file.

FUNCTION HOpenRF (vRefNum: Integer; dirID: LongInt;                   fileName: Str255; permission: SignedByte;                   VAR refNum: Integer): OSErr;
vRefNum
A volume reference number, a working directory reference number, or 0 for the default volume.
dirID
A directory ID.
fileName
The name of the file.
permission
The access mode under which to open the file.
refNum
The file reference number of the opened file.
DESCRIPTION
TheHOpenRF function creates an access path to the resource fork of a file. A file reference number for that file is returned in therefNum parameter.

SPECIAL CONSIDERATIONS
Generally, your application should use Resource Manager routines rather than File Manager routines to access a file's resource fork. TheHOpenRF function does not read the resource map into memory and is generally useful only for applications (such as utilities that copy files) that need block-level access to a resource fork. In particular, you should not use the resource fork of a file to hold nonresource data. Many parts of the system software assume that a resource fork always contains resource data.

RESULT CODES
noErr0No error
nsvErr-35No such volume
ioErr-36I/O error
bdNamErr-37Bad filename
tmfoErr-42Too many files open
fnfErr-43File not found
opWrErr-49File already open for writing
permErr-54Attempt to open locked file for writing
dirNFErr-120Directory not found or incomplete pathname
afpAccessDenied-5000User does not have the correct access to the file

PreviousBook ContentsBook IndexNext

Shop theApple Online Store (1-800-MY-APPLE), visit anApple Retail Store, or find areseller.

Copyright © 2016 Apple Inc. All rights reserved.


[8]ページ先頭

©2009-2025 Movatter.jp