CopyFileToDevice error on 1.5MB file...

Last post 07-02-2008 9:58 by cloftis. 1 replies.
Page 1 of 1 (2 items)
Sort Posts: Previous Next
  • 07-01-2008 11:27

    CopyFileToDevice error on 1.5MB file...

    I am trying to copy a file from my desktop to my WM6 device using CopyFileToDevice. This works for every file I have tried except for one and it is relatively large compared to the others - it is 1.53MB. Here's the error message that I am getting:

    OpenNETCF.Desktop.Communication.RAPIException: Could not open remote file at OpenNETCF.Desktop.Communication.RAPI.SetDeviceFileTime(String FileName, RAPIFileTime DesiredTime, DateTime NewTime) at OpenNETCF.Desktop.Communication.RAPI.CopyFileToDevice(String LocalFileName, String RemoteFileName, Boolean Overwrite...

    After the error inspection of the file reveals that it was transferred in it entirety - but as the error message above indicates, the date timestamp for the file is incorrect (+ an error is thrown). I've seen other posts where people claim to have transferred much larger files (5MB, 20MB, etc.) using this method but I'm not able to have the same success. Seems like file is still busy (and locked) when the SetDeviceFileTime methods fire...

    Anyone have any ideas as to the source of this problem and/or possible resolution?


    BTW, I have seen posts talking about the size of the transfer buffer size from 0x1000 to 0x4000 - would that help in this situation?
     

    Filed under: ,
  • 07-02-2008 9:58 In reply to

    Re: CopyFileToDevice error on 1.5MB file...

    This problem went away after I did a hard boot of the WM6 device - must not have been a problem with the code.

Page 1 of 1 (2 items)