Contents tagged with .NET code
-
Generating EF Code First model classes from an existing database
Entity Framework Code First is a lightweight way to "turn on" data access for a simple CLR class. As the name implies, the intended use is that you're writing the code first and thinking about the database later.
-
Subtext 2: OpenID Login Support
The recent Subtext 2 release includes a feature I worked on: OpenID login support. Let’s take a quick look at how you use it, then we’ll talk about the how the code works and why it’s a useful feature.
-
Ten Tips for a Happy Upgrade to Visual Studio 2008 (Release)
Visual Studio 2008 has been out for over a week. I've upgraded three machines (two Vista, one XP) from Beta 2 to RTM, then upgraded a couple of projects. I've also been watching blog posts and listening in at the Twitter water-cooler to hear about other developers' experiences, problems, and recommendations as they go through the upgrade experience. So, here's my quick guide to a smooth upgrade to Visual Studio 2008.
-
Creating Zip archives in .NET (without an external library like SharpZipLib)
SharpZipLib provides best free .NET compression library, but what if you can't use it due to the GPL license? I'll look at a few options, ending with my favorite - System.IO.Packaging.
-
Silverlight 1.1 (Alpha) cross domain webservice access makes mashups tricky
Any web mashups, by definition, require cross-domain calls. Those cross-domain calls may happen on the client (in the browser) or on the server. Regardless of the client technology (AJAX, Flash, Silverlight, etc.), cross domain calls on the client are always more complex that server-side cross-domain calls, and for good reason. It's tricky in AJAX, and it's downright difficult in Silverlight. You'll know that Silverlight development has become more widespread when you hear a lot more complaints about this problem.
-
Some keyboard input tricks for Silverlight 1.1 (Alpha)
Here are a few tricks I learned while doing my "hello world" maze game in Silverlight 1.1.
-
VB.NET vs. C#, round 3?
VB.NET gets a hard time from C# developers. For a variety of reasons, the leading .NET programmers seem to be working in C#, and VB.NET developers get really tired of saying, "Hey, VB.NET can do that, too!"
-
CodePlex is adding support for <strike>Subversion</strike> TortoiseSVN
I just heard that CodePlex is adding support for TortoiseSVN with an estimated release date of June 5.
-
MIX07 - WCF adding System.UriTemplate, [WebGet], and [WebInvoke]
Build and parse URI's
System.UriTemplate (Orcas) - runtime support for URI template syntax
UriTemplate.Bind - A safe, smart string.format for URI construction
UriTemplate.Match - Extracts URI to dictionary
UriTemplateTable - One or more template, best match winsHTTP GET - bound semantics, expectation of idempotency, generally "safe" Chaos - HTTP POST, PUT, DELETE, others
WebHttpClient client = new WebHttpClient() { UriTemplate = "http://localhost/mix/data/symbols{0}"; } MixData = client.Get(StockSymbol).GetBody
(); return data; -
Sending files via the default e-mail client
I recently released a "Send To Email" plugin for Cropper, which makes it easy to grab a portion of your screen and send it as an e-mail attachment. It's easy enough to directly send an e-mail in .NET using System.Net.Mail, but there's no provision for sending a mail using the default client.