Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Unable to use System.Threading.Tasks in WP7 application

I recently completed a library for a online storage website that allows for me to call the PHP exposed RESTs between the file storage website and a windows form desktop client + Outlook add in.

Now, here is a question that has the code sample for the most basic operation in the library: Gracefully killing a TPL Task. I'm linking it for reference only. My next objective is a Windows Phone 7 client.

I knew I simply cannot use the same library as I need a different kind of class library for a WP7 app. So i went forward and created a WP7 version of the library hoping most of the stuff will work. I hit a road block immediately when I realized that I don't have access to the most critical class: a TPL Task.

Am I missing something here? Any advice? Thanks.

like image 627
Hassan Gulzar Avatar asked Nov 27 '11 15:11

Hassan Gulzar


1 Answers

OK. Apparently, there is no official System.Threading.Tasks for a WP7 project. However, after getting proper sleep and searching again, i found that a package exists at NuGet that simply answers all my needs: Task Parallel Library for Silverlight. The version is at 2.1.2 at the time of writing.

like image 131
Hassan Gulzar Avatar answered Oct 05 '22 04:10

Hassan Gulzar