Windows Home Server and the Task Parallel Library RRS feed

  • Question

  • Firstly apologies as this is a cross post question from stack overflow - http://stackoverflow.com/questions/7915423/windows-home-server-and-the-task-parallel-library. Sorry if this is against the rules!


    I have some very simple class library with code as follows:-

    public Task<string> ConnectAsync()
        Task<string> result = Task.Factory.StartNew(()=> Connect());
        return result;
    public string Connect()
        return "Test";

    In my front end I have the following:

    Task<string> myTask = connection.ConnectAsync();
    myTask.ContinueWith(ant =>
        label1.Invoke((MethodInvoker)(() => label1.Text = ant.Result));

    In a normal windows form this works as expected, no UI lock up's. However when I push exact code out as a windows home server 2011 plugin its a different storey. The UI locks up and eventually the dashboard is killed automatically.

    Any help would be really appreciated!




    • Edited by RossDargan Thursday, October 27, 2011 11:56 AM
    Thursday, October 27, 2011 11:55 AM


  • daft mistake - the third party library wasn't been copied over with the addin which is why it errors
    Thursday, October 27, 2011 12:09 PM