views:

41

answers:

1

Let's say I want to create an application, fairly simple CRUD with 3-5 tables. Imagine a Todo list application for example.

What is the best way to approach the data layer in WPF for this to be a click-once application. I'd rather not do it in the cloud (although if I can add an easy backup process in the background, that's a big plus).

I've heard of SQL compact something 2005, but I couldn't find a comprehensive guide from start to finish, and how to use the awesome table designer thingie - Is that the best approach?

Is it easier to plugin a sql lite like there is one in AIR? Do people do such thing?

Or suffer using XML for each and use some linq magic between the collections?

As you can tell I haven't got much background in microsoft technologies, but I'd like to write some good software and I'd like to know the right way, rather than the hack way.

Thanks.

+2  A: 

Usually I combine a ClickOnce frontend with a web services / WCF backend (DAL and/or BLL). No problems with firewalls etc then - if you wanted it hosted centrally that is.

There's SQL Server 2005 Express: right-click and Add new item.. to the project and find an .MDB: then on the ClickOnce deployment page you can have the installer automatically install the SQL Server Express for you, and you can use your .mdb without much hassle at all!

SQLLite is available for .NET, I have considered but not tried it yet:

http://sqlite.phxsoftware.com/

Hope that helps.!

Kieren Johnstone
I can heartily recommend the ADO.NET wrapper for sqlite cited above. Recently a new version was released with support for foreign keys. I am using it for an aplication with some 30 users that cause updates to three tables on a server. Works flawlessly.
Dabblernl
Thanks both! I've tried using sqlCE thingie but sqllite might be a better option?
keyle