info("dropfiles")

The info(“dropfiles”) function returns a list of files dragged onto a Drag Receiver form object (see Drag and Drop).


Description

This function returns a list of files and folders dragged onto a Drag Receiver form object (see Drag and Drop). It should only be used in a procedure triggered by that type of object. Each file is listed on a separate line as a full UNIX path and filename. Here is typical output produced by dragging 5 PDF files from the Downloads folder onto the Drag Receiver object.

/Users/johnsmith/Downloads/2010 Annual Report.pdf
/Users/johnsmith/Downloads/2011 Annual Report.pdf
/Users/johnsmith/Downloads/2012 Annual Report.pdf
/Users/johnsmith/Downloads/2013 Annual Report.pdf
/Users/johnsmith/Downloads/2014 Annual Report.pdf

This example imports the text contained in the dropped files into the current database.

window info("dropwindow")
looparray info("dropfiles"),cr(),dropfile
    importtext fileload(dropfile)
endloop

Note: If the Drag Receiver object has been configured to only accept certain types of files, only those files will be returned by the info(“dropfiles”) function. For example, suppose the Drag Receiver object has been set up to only accept .pdf files. If you drag three files onto this object, a PDF file, a JPEG image, and an HTML file, only the PDF file will be returned by the *info(“dropfiles”) function.


Error Messages

No dropped files. – No files were dropped on the Drag Receiver object (perhaps some other type of data was dropped).


See Also


History

VersionStatusNotes
10.0NewNew in this version.