CreateFile() 인자값

2010. 9. 30. 15:08언어/Computer English

dwShareMode

The sharing mode of an object, which can be read, write, both, delete, all of these, or none: 0, FILE_SHARE_DELETE, FILE_SHARE_READ, FILE_SHARE_WRITE.

lpSecurityAttributes

A pointer to a SECURITY_ATTRIBUTES structure that contains an optional security descriptor and also determines whether or not the returned handle can be inherited by child processes.The parameter can be NULL.

dwCreationDisposition

An action to take on files that exist and do not exist.This parameter must be one of the following values, which cannot be combined: CREATE_ALWAYS, CREATE_NEW, OPEN_ALWAYS, OPEN_EXISTING, or TRUNCATE_EXISTING.

dwFlagsAndAttributes

The file attributes and flags.This parameter can include any combination of the available file attributes (FILE_ATTRIBUTE_*).All other file attributes override FILE_ATTRIBUTE_NORMAL.This parameter can also contain combinations of flags (FILE_FLAG_*) for control of buffering behavior, access modes, and other special-purpose flags.These combine with any FILE_ATTRIBUTE_* values.

hTemplateFile

A valid handle to a template file with the GENERIC_READ access right.The template file supplies file attributes and extended attributes for the file that is being created.This parameter can be NULL.