TaskController in Windows Phone 8

Topics: Actions & Coroutines, Bugs
Jan 6, 2013 at 10:51 AM

Hi everyone,

I changed the projectType from my running WP 7.1 App to WP8. Running my App under the new version exposed some issues with the TaskController running under WP8

I use the following code in the ViewModel:

public void ChooseAddress(){
  _eventAggregator.RequestTask<AddressChooserTask>();
}

calling this method results in a "System.ArgumentException" within the caliburn micro framework:

IHandle<TaskExecutionRequested>.Handle(TaskExecutionRequested message)
{
 ...
 @event.AddEventHandler(message.Task, Delegate.CreateDegate(@event.EventhandlerType, this, "OnTaskComplete"));
}

System.ArgumentException:
Message: "Cannot bind to the target method because its signature or security transparency is not compatible with that of the delegate type." 

(The issue occured on the latest stable version as well when i build the latest version from git)

Any Ideas?

Jan 6, 2013 at 12:23 PM

May you create an issue and add a small sample that shows the problem, please.

Jan 6, 2013 at 4:57 PM

I created an issue and added two small sample projects:
http://caliburnmicro.codeplex.com/workitem/274  

Jan 6, 2013 at 6:33 PM

If you fetch the latest sources it should work now.

Jan 6, 2013 at 7:43 PM

thanks! the applied fix works for WP8 as well as WP7.1