/ Published in: C#
Example written 01/13/2011
The following code shows how to implement functionality in your Windows Forms application, such that you'll be able to open a file that is dragged and dropped onto your program's form. This behavior is often desirable for programs that manipulate files in some way (renamers, encrypters, etc.) It's also nice for the uer to be able to have more than one way to open a file. This example implements opening via drag-dropping, and via a customary File->Open menu.
The following code shows how to implement functionality in your Windows Forms application, such that you'll be able to open a file that is dragged and dropped onto your program's form. This behavior is often desirable for programs that manipulate files in some way (renamers, encrypters, etc.) It's also nice for the uer to be able to have more than one way to open a file. This example implements opening via drag-dropping, and via a customary File->Open menu.
URL: http://kyrathaba.dcmembers.com/errata/openFileDroppedOntoForm.htm