How to overwrite?

May 8, 2012 at 2:50 PM

Hello there,

is there an easy way to have the SkyDrive client overwrite a file on upload instead of creating a dupe (filename (2))?

Thank you.

Coordinator
Mar 8, 2013 at 10:56 AM
Hmm, the answer might be in the following lines of code:
                        new CreateSubFolderItemRequest
                        {
                            Title = Path.GetFileName(fileName),
                            Type = folderItemType,
                            ResolveNameConflict = true
                        },
Perhaps ResolveNameConflict is responsible for this dupe effect.
Coordinator
Mar 8, 2013 at 1:01 PM
Well, out-of-the-box, you cannot overwrite a file.
I tried to set ResolveNameConflict to false and resulted in Forbidden HTTP result.
This means, you have to handle the overwrite (delete old file first than upload the new file)