Click here to Skip to main content
Rate this: bad
good
Please Sign up or sign in to vote.
See more: C# Silverlight
So Im trying to upload an audio file (3 megabytes) using the Live SDK in Windows Phone 7. Everything works fine until the upload is finish where it always throw an ObjectDisposeException. But the file is on the skydrive correctly and gets to 100% upload is just that it throws the exception even in a try catch.
 
code:
client.BackgroundUploadAsync("me/skydrive/",
                  new Uri("/shared/transfers/" + song.ID, UriKind.RelativeOrAbsolute), OverwriteOption.Rename, "mdfs");
 
Any ideas?
Posted 2-Sep-12 8:20am
Zumicts521
Comments
Ed Nutting at 2-Sep-12 14:55pm
   
Hmm...it's an Async operation so my bet is that there is a possible bug in the SDK that means that when it's 100% uploaded, the uploader thread tries to access it's creator thread by which point that creator thread has been disposed of and so you get the error. Certainly the reason a try-catch block doesn't work for you is because Async creates a new thread on which the error is then occurring. I will not explain threading here as there are many articles on it but it means the error jumps all the way up to the process as a whole and any try-catch block round the code you present is completely irrelevant - it's hard to explain without explaining threading as a whole - please read up on it as an issue. My advice would be to check the SDK forums (by searching in Google or on the SDK's development site) to see if this is a known issue or if other have come across it/solved it.
 
Ed
XzRaider27 at 15-Sep-12 20:57pm
   
Been searching on google for a few days and nothing so far.... Anybody has been able to solved this?

1 solution

Rate this: bad
good
Please Sign up or sign in to vote.

Solution 1

Firt you shoud copy the song to the directory /shared/transfers/ ,then upload
  Permalink  

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)

  Print Answers RSS
0 OriginalGriff 381
1 Sergey Alexandrovich Kryukov 245
2 Marcin Kozub 225
3 Praneet Nadkar 217
4 /\jmot 189
0 OriginalGriff 8,284
1 Sergey Alexandrovich Kryukov 7,407
2 DamithSL 5,614
3 Maciej Los 4,989
4 Manas Bhardwaj 4,986


Advertise | Privacy | Mobile
Web01 | 2.8.1411023.1 | Last Updated 2 Nov 2014
Copyright © CodeProject, 1999-2014
All Rights Reserved. Terms of Service
Layout: fixed | fluid

CodeProject, 503-250 Ferrand Drive Toronto Ontario, M3C 3G8 Canada +1 416-849-8900 x 100