QD_SetDroppableFileExtensions
QD_SetDroppableFileExtensions(areaRef; fileExtensions):error | |||
---|---|---|---|
![]() |
areaRef | Longint | Area reference |
![]() |
fileExtensions | Array text | Droppable file name extensions |
![]() |
error | Longint | Error result |
Configure a QDrop area to accept specific file extensions
Parameter areaRef is the reference to the plug-in area.
Parameter fileExtensions is a text array that specifies file extensions that the area will accept. File extensions should be specified without the period (.) separator.
In addition to standard file extensions such as "txt" and "jpg", a set of magic file types that provide extra matching criteria can also be used.
qd_anyFileMagic | "any*" | Accept any file |
qd_folderMagic | "dir*" | Accept folders |
Example
// Accept text files and folders C_LONGINT($error) ARRAY TEXT($fileExtensions;2) $fileExtensions{1}:="txt" $fileExtensions{2}:=qd_folderMagic $error:=QD_SetDroppableFileExtensions(xDrop;$fileExtensions)
Related commands
QD_GetDroppableFileExtensions | Get the file extensions accepted by a QDrop area |