Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Azure Mobile Services: Invalid Operation Exception (platform-specific assembly not found)

I have developed an app on Xamarin.iOS using Azure Mobile Services component, it has been working fine, just today I made some changes and then I started getting this exception. No matter what I do, it still thinks that this .Ext library is missing

Windows Azure Mobile Services assembly for the current platform was not found. Ensure that the current project references both Microsoft.WindowsAzure.Mobile and the following platform-specific assembly: Microsoft.WindowsAzure.Mobile.Ext.

I have made sure to remove and install the component via Xamarin.Studio, I have also added manual reference to the libraries (with the platform-specific extension) but still no use.

Any ideas?

like image 661
Has AlTaiar Avatar asked Jul 02 '14 00:07

Has AlTaiar


1 Answers

I found the solution in this blog post

Appearantly I missed one line in the set up of the Mobile Services on the mobile, which is:

CurrentPlatform.Init();

Once I added this line, the problem is gone. It must have been using old dlls before I cleaned up the solution and moved some code around then it started breaking. Adding the line above fixed it for me, and hope it helps somebody else.

like image 86
Has AlTaiar Avatar answered Nov 11 '22 17:11

Has AlTaiar