Had a similar problem when the software installed on the PC had to have access to the file inside the Android phone via USB. After much research, this is what worked for me (not sure if this is the best solution, but it worked). Windows has a Windows Portable Device (WPD) API that can be used to list the contents of a device via USB (and copy files between the client and the device).
There are several implementations in java http://code.google.com/p/jmtp/ (it works well, but does not support the copy function from the device to the PC, although there is some support available for this with the source code) the other is jusbpmp (available in the Google repository) (if someone discovers that a well-documented and supported implementation does share)
but since jmtp did not work for me (copying the original compilation (for a 64-bit OS) failed), I wrote a C # program from scratch to copy files from the device to the PC. here is a good tutorial http://cgeers.com/2011/08/13/wpd-transferring-content/
source share