Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Using C# to create a frontend for a simple database

Tags:

c#

winforms

I've only used C# to create console apps up to now. What I would like to do next is create a c# application that could open a one table database (probably sqlite) and present the data in table form to the user. I'd like the user to be able to do things like sort by column, search etc. I have a couple of questions with regards to the GUI piece.

What would be the appropriate .Net technology to use for the GUI front end? WinForms?

I would really appreciate a link to a tutorial or worked example of doing something similar

Any help appreciated.

like image 978
halfpint Avatar asked Mar 23 '11 09:03

halfpint


2 Answers

This tutorial shows you how to create a DataGridView, load database values in it. The sorting is an automatic property of the DataGridView. The DataGridView is a control used in a WinForms application, which seems the best solution for your needs.

like image 86
Steven Ryssaert Avatar answered Sep 19 '22 01:09

Steven Ryssaert


In your situation I would start with WinForms as GUI technology - simpler and more mature than WPF.

Here

http://www.codeproject.com/KB/cs/SQLiteCSharp.aspx

you find an example application for a single table SqlLite DB.

like image 33
Doc Brown Avatar answered Sep 19 '22 01:09

Doc Brown