android - How handle exception while copying files from phone to pc in C#? -
i'm trying copy files connected android device pc.
public void copyfiles(folder srcfolder, folder folderimages, folder folderdatabase) { imagefilecounter = 0; sqllitecounter = 0; foreach (folderitem currfolderitem in srcfolder.items()) { if (currfolderitem.isfolder) continue; if (currfolderitem.type.equals("jpg file") || currfolderitem.type.equals("png file")) { folderimages.copyhere(currfolderitem, 4 | 16); imagefilecounter++; } else if (currfolderitem.type.equals("data base file")) { folderdatabase.movehere(currfolderitem, 4 | 16); sqllitecounter++; } } }
and want handle copy error when device disconnect while copying files. can know how can that?
i found solution. there no way information folder.copyhere() or folder.movehere() final result. found answer here https://msdn.microsoft.com/pl-pl/library/windows/desktop/bb787866(v=vs.85).aspx. sorry silly question.
Comments
Post a Comment