Forum Cross Platform with Xamarin


The Xamarin Forums have officially moved to the new Microsoft Q&A experience. Microsoft Q&A is the home for technical questions and answers at across all products at Microsoft now including Xamarin!

To create new threads and ask questions head over to Microsoft Q&A for .NET and get involved today.

How do we use SqLiteNetExtensions in a windows phone 8 project?

Hi Team :
Let me know how i can use the SqLiteNetExtensions dll in a windows phone project?
I am using SqLite.cs and SqLiteAsync.cs as the API for sqlite database access.
But I am not able to access the extension methods GetWithChildren,UpdateWithChildren etc
in my connection object.
var c = new SQLiteConnection(SqlDatabaseFileName);
var storedValuation = c.GetWithChildren<OnBoardPOS.WP8.Framework.Model.Order>("12");// compiler tell that no such method or extension method or extension method has some invalid arguments etc.
a)I have referenced the SqLiteNet and SqLiteNetExtensions. dll in the project
b)I have referenced the namespaces SQLiteNetExtensions.Attributes SQLiteNetExtensions.Extensions; on top of the class
It seems to me that the SqLiteExtensions works only on top of some MVVMCross SqLite plug in and not on the SqLite.
Please let me know if anyone has done this .
The sample TaskyPro example uses only SqLite-Net.I need a sample or advice on how to integrate SqLiteNetExtensions in windows Phone project.
Or is it possible only in iphone/android environments?

Best Answer


  • GuillermoGutierrezGuillermoGutierrez ESMember ✭✭✭

    The main issue is that there's no PCL compliant version of SQLite-Net, so you cannot use SQLite-Net in the PCL Core project, that's why we are using the MvvmCross SQLitePlugin in the PCL project.

  • I have created a PCL version of sqlite-net, called SQLite.Net PCL, available on github and as a nuget (though I not yet created a platform module for wp8, pull requests welcome are welcome).

Sign In or Register to comment.