Код:
FileCount := DragQueryFile(Message.Drop, $FFFFFFFF, Nil, 0); // how many files are dropped
For I := 0 to FileCount - 1 Do // for all the file in the list
Begin
DragQueryFile(Message.Drop, I, FileName, 256); // get the FileName (max characters 255 + #0)
If FileExists(FileName) Then
Begin
// Add your code here...
End;
End;
По сути вот здесь как раз и говориться что принемаеться только фаилы)
или как вариант вот здесь попробовать
Код:
If FileExists(FileName) Then
Begin
// Add your code here...
End;
ExtractFileDir
__________________
Delphi - это лишь инструмент, а что ты сможешь создать при помощи этого инструмента, зависит исключительно от тебя.
|