Was this page helpful?
Your feedback about this content is important. Let us know what you think.
Additional feedback?
1500 characters remaining
MSDN Library


Windows Mobile 6.5
A version of this page is also available for

This function obtains attribute information about a specified file or directory.

This function is similar to the GetFileAttributes function. GetFileAttributes returns a set of FAT-style attribute information. This function obtains other sets of file or directory attribute information. Currently, this function obtains a set of standard attributes that is a superset of the FAT-style attributes.

BOOL GetFileAttributesEx(
  LPCTSTR lpFileName, 
  LPVOID lpFileInformation 


[in] Pointer to a null-terminated string that specifies a file or directory.

By default, this string is limited to MAX_PATH characters. The limit is related to how this function parses paths. Windows Embedded CE does not support the \\?\ override of the MAX_PATH limit and does not support wildcard characters.


[in] GET_FILEEX_INFO_LEVELS enumeration type that specifies the set of attribute information to obtain.


[out] Pointer to a WIN32_FILE_ATTRIBUTE_DATA structure that receives the attribute information.

Nonzero indicates success. Zero indicates failure. To get extended error information, call GetLastError.

Windows Embedded CEWindows CE 3.0 and later
Windows MobileWindows Mobile Version 5.0 and later

Community Additions

© 2015 Microsoft