- edited description
How to create a SQLite database compatible with Windows 8 App?
Comments (5)
-
reporter -
Hi Alexey,
I don't know if SQLite-Net PCL is compatible with Windows 8. You can try adding the SQLite-Net PCL for Windows Phone 8 to see if it works ( https://www.nuget.org/packages/SQLite.Net.Platform.WindowsPhone8 ). Otherwise try using whatever SQLite-Net version that works for you and just copy the SQLite-Net Extension sources to your project to link it with your SQLite-Net version.
Hope it helps.
-
reporter Can support Win32 and WinRT... How can I create a project from scratch? How create connection use Platform.Win32..... Which extensions you need to install and in what order ... Thank you so much for your help. I am writing an application and I need support relationships between tables. Thank U! (Google translate)
using System.Collections.Generic; using System.Linq; using NUnit.Framework; using SQLite.Net.Attributes; #if __WIN32__ using SQLitePlatformTest = SQLite.Net.Platform.Win32.SQLitePlatformWin32; #elif WINDOWS_PHONE using SQLitePlatformTest = SQLite.Net.Platform.WindowsPhone8.SQLitePlatformWP8; #elif __WINRT__ using SQLitePlatformTest = SQLite.Net.Platform.WinRT.SQLitePlatformWinRT; #elif __IOS__ using SQLitePlatformTest = SQLite.Net.Platform.XamarinIOS.SQLitePlatformIOS; #elif __ANDROID__ using SQLitePlatformTest = SQLite.Net.Platform.XamarinAndroid.SQLitePlatformAndroid; #else using SQLitePlatformTest = SQLite.Net.Platform.Generic.SQLitePlatformGeneric; #endif namespace SQLite.Net.Tests { [TestFixture] public class IgnoredTest { public class DummyClass { [PrimaryKey, AutoIncrement] public int Id { get; set; } public string Foo { get; set; } public string Bar { get; set; } [Attributes.Ignore] public List<string> Ignored { get; set; } } [Test] public void NullableFloat() { var db = new SQLiteConnection(new SQLitePlatformTest(), TestPath.GetTempFileName()); // if the Ignored property is not ignore this will cause an exception db.CreateTable<DummyClass>(); } } }
-
Hi Alexey, that code seems correct. What errors are you getting?
-
- changed status to closed
More than one month with no response. I'm closing the issue. Feel free to open it again if you experience problems in the future.
- Log in to comment