Friday, June 18, 2010
Deploying SQL Server Compact Edition
In the interest of copy and paste and making your life easier, here are the 7 dll’s you need to locate and add to your project. You should be able to find them in C:\Program Files\Microsoft SQL Server Compact Edition\v3.5 (or v3.0). If you are using 3.0, substitute “30” for “35” in the names of these dll’s.
- sqlceca35.dll
- sqlcecompact35.dll
- sqlceer35EN.dl
- sqlceme35.dll
- sqlceoledb35.dll
- sqlceqp35.dll
- sqlcese35.dll
Set the Build Action to “Content”, and “Copy to Output Directory” to “copy always” on these entries in Solution Explorer. On the reference to the System.Data.SqlServerCe.dll in your project, set “Copy Local” to “true”.
Wednesday, April 21, 2010
JSON.NET
Json - Release: Json.NET 3.5 Release 7
Json.NET library makes working with JSON formatted data in .NET simple. Key features include a flexible JSON serializer to for quickly converting .NET classes to JSON and back again, and LINQ to JSON for reading and writing JSON.
Features
-Flexible JSON serializer to convert .NET objects to JSON and back again
-LINQ to JSON for reading and writing JSON
-Writes indented, easy to read JSON
-Convert JSON to and from XML
-Supports Silverlight and the Compact Framework
The JSON serializer is a good choice when the JSON you are reading or writing maps closely to a .NET class. The serializer automatically reads and writes JSON for the class.
For situations where you are only interested in getting values from JSON, don't have a class to serialize or deserialize to, or the JSON is radically different from your class and you need to manually read and write from your objects then LINQ to JSON is what you should use. LINQ to JSON allows you to easily read, create and modify JSON in .NET.
Thursday, April 1, 2010
Easiest way to set ListView ItemHeight in an Owner-Drawn ListView
When creating an owner-drawn ListBox, you will receive measure-item messages that allow you to specify the height of items. In a ListView control, that functionality is not there. So how is the ItemHeight determined in a ListView in Details mode? It uses the ImageList height then the Font height, so to override the item height create a dummy ImageList and set it to the desired height and assign it to the listview depending on the view. Using the Font to set the height does not work very well because it also affects the height of the Header control, an unwanted side-effect.
Wednesday, March 17, 2010
HUDZEE
If you have extra 3.5" internal hard drives, perhaps for backups or archiving purposes, what's the best way to store them? This is the answer – a VHS-like static-free enclosure that can be placed on a bookshelf. I found a similar item on Amazon, but it looks flimsy and apparently has one side longer than the other so you can't stand it straight up on a bookshelf. The Hudzee looks strong, snug, and will store nicely on a bookshelf. They're about $65 for 10 of them, not very cheap, but if you have hard drives accumulating, it's a good investment.
http://hudzee.com/
Friday, March 12, 2010
Jazzercise!
http://christoffer-workout.blogspot.com/
