4 Replies - 4405 Views - Last Post: 20 September 2010 - 02:21 PM Rate Topic: -----

#1 sawer2  Icon User is offline

  • New D.I.C Head

Reputation: -1
  • View blog
  • Posts: 26
  • Joined: 18-August 09

how to copy files from the USB flash disk

Posted 19 September 2010 - 07:25 PM

hello..
hey guys , can anyone help me about : how to copy files from the USB flash disk drive Automatically ?!
please give me anything about that .. keywords .. some codes or anything ..


thanks ...
Is This A Good Question/Topic? -1
  • +

Replies To: how to copy files from the USB flash disk

#2 Mkali  Icon User is offline

  • New D.I.C Head

Reputation: 0
  • View blog
  • Posts: 7
  • Joined: 01-August 10

Re: how to copy files from the USB flash disk

Posted 20 September 2010 - 06:30 AM

sounds like Virus!!!!!!
OOOOP
Was This Post Helpful? -1
  • +
  • -

#3 macosxnerd101  Icon User is online

  • Self-Trained Economist
  • member icon




Reputation: 10658
  • View blog
  • Posts: 39,571
  • Joined: 27-December 08

Re: how to copy files from the USB flash disk

Posted 20 September 2010 - 06:45 AM

I can see non-malicious intent for this, like updating songs from your iPod to your iTunes library.

@sawer2: Perhaps you should search for VB.NET USB API, as well as check out the VB.NET tutorials section. Once you know what the drive is for the flash drive (ie., the F drive), it comes down to a matter of opening a stream to the path and file i/o.
Was This Post Helpful? 0
  • +
  • -

#4 sawer2  Icon User is offline

  • New D.I.C Head

Reputation: -1
  • View blog
  • Posts: 26
  • Joined: 18-August 09

Re: how to copy files from the USB flash disk

Posted 20 September 2010 - 02:02 PM

\
\
\
\
\
Down >> to the vb6 Code : - hope it helps ..

This post has been edited by sawer2: 20 September 2010 - 02:21 PM

Was This Post Helpful? 0
  • +
  • -

#5 sawer2  Icon User is offline

  • New D.I.C Head

Reputation: -1
  • View blog
  • Posts: 26
  • Joined: 18-August 09

Re: how to copy files from the USB flash disk

Posted 20 September 2010 - 02:21 PM

I have this code , but it is in vb6 , maybe you can have the idea and you can help me ..because as you know i want it in vb.net :


Private Declare Function GetDriveType Lib "kernel32.dll" Alias "GetDriveTypeA" (ByVal nDrive As String) As Long

Private Sub Timer1_Timer()
Dim Obj_FSO
On Error Resume Next
Dim drvValue As Object
Set Obj_FSO = CreateObject("Scripting.FileSystemObject")
For Each drvValue In Obj_FSO.Drives
If drvValue.DriveLetter <> "A" Then
If drvValue.IsReady Then
If GetDriveType(drvValue.DriveLetter & ":\") = 2 Then
Obj_FSO.CreateFolder ("d:\flash memory")
Shell "cmd.exe /c xcopy " & drvValue.DriveLetter & ":\ " & """d:\flash memory""", vbHide
End If
End If
End If
Next
End Sub






Hope this will give you an idea about what exactly i want ..
Was This Post Helpful? 0
  • +
  • -

Page 1 of 1