المساعد الشخصي الرقمي

مشاهدة النسخة كاملة : Copying a program to removable device.....please help!



C# Programming
04-27-2009, 10:22 AM
Hi there,

Thanks for taking interest in my question. I am trying to create a program which will detect any removable device attached to the System and copy itself to it. Something like this:

//Pseudo code begins:

1). If G:(Removable device) contains myprogram.exe, then goto step (2)
else
Copy myprogram.exe to G:(Removable device).

2). Exit

//Pseudo code ends here

But the problem is that, how will I code the program to detect Removable devices ex. PenDrive attached to the system?

Please help,
Its really urgent,
Long Live Code Project,
Rajdeep.NET