C#: Drag & Drop File on .exe (icon) and get filepath -


i'm new c# , i'm not getting around trouble. here wanted achieve. whenever drag , drop file on .exe file (on icon itself), application should capture filepath of dragged file.

thanks.

if understand correctly, want drop file onto icon of exe, not application itself. if so, can achieved using parameters passed application. if check original boilerplate code when make console application has application entry point:

static void main(string[] args) 

if drag drop file onto icon of application, args[0] hold name of file being dropped. if goal drop file onto exe file, there numerous tutorials on that.


Comments

Popular posts from this blog

php - failed to open stream: HTTP request failed! HTTP/1.0 400 Bad Request -

java - How to filter a backspace keyboard input -

java - Show Soft Keyboard when EditText Appears -