How to drag and droping folders using C#

Jun 26 2007 6:57 PM
Hi I am pretty new to C# but I am trying to get the hang of it. I made my first program yesturday and I am looking to add to it. What it does: You drag and drop two files into the window and it checks to see if their exension is .jar or .jad if it is it renames it to _jar or _jad respectivly. I made this for my cellphone because when I put games or applications on it they need to be named a certain way. This is a snippet of code so don't worry about the {'s. the snippet is here: http://pastebin.ca/591040 So I got a working program.. but It is still a hassle to go into every single folder and drag the files so I needed to make it look in directories for files. So I made it check if it was a directory or not using if((System.IO.File.GetAttributes(file) & System.IO.FileAttributes.Directory) == System.IO.FileAttributes.Directory) { } then I was stumped. Please help me implement drag and drop folder support and maybe even drag and drop subfolder support. Thank you. -goatmale

Answers (3)