Главная страница
Top.Mail.Ru    Яндекс.Метрика
Текущий архив: 2002.10.03;
Скачать: CL | DM;

Вниз

Search   Найти похожие ветки 

 
DeepProg ©   (2002-09-21 17:40) [0]

GD!
Уже несколько раз обращался сюда с подобным вопросом, но никто так и не ответил. May be this time?

Вопрос:
Как можно организовать поиск файлов по дате последненего доступа к ним, последнего открытия, по какому-либо определенному свойству (ч.-н. более обширное, чем архивный, скрытый, только чтение)

Может ссылки на такие работы кто знает, ведь реализовали же это в Винде...


 
MBo ©   (2002-09-21 19:48) [1]

> но никто так и не ответил
Потому что в хелп надо самому смотреть на FindFirst


 
Алексей Ким ©   (2002-09-21 20:22) [2]

The GetFileTime function retrieves the date and time that a file was created, last accessed, and last modified.

BOOL GetFileTime(

HANDLE hFile, // identifies the file
LPFILETIME lpCreationTime, // address of creation time
LPFILETIME lpLastAccessTime, // address of last access time
LPFILETIME lpLastWriteTime // address of last write time
);
Parameters

hFile

Identifies the files for which to get dates and times. The file handle must have been created with GENERIC_READ access to the file.

lpCreationTime

Points to a FILETIME structure to receive the date and time the file was created. This parameter can be NULL if the application does not require this information.


lpLastAccessTime

Points to a FILETIME structure to receive the date and time the file was last accessed. The last access time includes the last time the file was written to, read from, or, in the case of executable files, run. This parameter can be NULL if the application does not require this information.

lpLastWriteTime

Points to a FILETIME structure to receive the date and time the file was last written to. This parameter can be NULL if the application does not require this information.

Return Value

If the function succeeds, the return value is TRUE.
If the function fails, the return value is FALSE. To get extended error information, call GetLastError.

Remarks

The FAT, NTFS, and HPFS file systems all support the file creation, last access, and last write time values.
Windows 95: The precision of the time for a file in a FAT file system is 2 seconds. The time precision for files in other file systems, such as those connected through a network depends on the file system but may also be limited by the remote device.

See Also

FILETIME, GetFileSize, GetFileType, SetFileTime

прям из хелпа


 
DeepProg ©   (2002-09-22 14:53) [3]

Как добраться до необходимых параметров поля в принципе ясно,
но вот как это реализовать в FindFirst
т.е. какой параметр-то надо установливать? (Time, ExcludeAttr, FindData)
в общем, примерчик бы...


 
Song ©   (2002-09-22 17:28) [4]

>>т.е. какой параметр-то надо установливать?
Параметр TSearchRec.Name



Страницы: 1 вся ветка

Текущий архив: 2002.10.03;
Скачать: CL | DM;

Наверх




Память: 0.47 MB
Время: 0.011 c
1-7925
tytus
2002-09-23 19:53
2002.10.03
Вторая форма


3-7879
Engel
2002-09-12 18:40
2002.10.03
Работа DBASE IV в сети.


3-7792
Uliana
2002-09-11 15:56
2002.10.03
Как сохранить картинку в БД...


14-8136
Usre
2002-09-08 23:38
2002.10.03
Аффоризмом в глаз!!!


1-7937
kex86
2002-09-24 01:34
2002.10.03
ХР