Hello everyone, I am not an expert on this technology yet, so I guess for most this is a very basic question... But I don't really know how to use DBContext and how can I really connect my database, to the cross-platform solution file... and which nuget packages should I use?... where do I reference it?... what classes should I make and what codes do I put in it?... These questions, that I don't even know how to apply on my solution, I hope it doesn't bother you guys...
My goal is to make a datagrid using xaml grid, binded with sqlite database using entity framework core 2.1...
If you can answer my question in a step-by-step guide that would be really helpful for me...
*How can I setup the Entity Framework Core 2.1 using the database that I created from sqlite? * My Database Location & Name: C:\sqlite\demo.db * My Target Framework: .Net Standard 2.0 * My Visual Studio Version: 15.7.2 * For Android, IOS, & UWP
Answers
Please follow my tutorials. In this example i am creating and hosting my database to azure portal but you can host on local or at other cloud.
Developing RESTful API in ASP.Net With Azure Database.
Part 1
https://c-sharpcorner.com/article/creating-sql-database-in-azure-portal/
part 2
https://c-sharpcorner.com/article/developing-restful-api-in-asp-net-with-add-method/
Part 3
https://c-sharpcorner.com/article/developing-restful-apis-in-asp-net-with-retrieve-update-and-delete-functions/
Consuming RESTful API in Xamarin.Android
part 4
https://c-sharpcorner.com/article/consuming-restful-apis-in-xamarin-android/