Thoughts from Dan Miser RSS 2.0
# Thursday, November 05, 2009
It looks like the blog shut down on 10/20/09. The problem turned out to be that I had exceeded the quota for the user account that hosts dasBlog. I bumped up the quota for that user, and now we should be good to go again. Until the next post...
Thursday, November 05, 2009 10:01:22 AM (Central Standard Time, UTC-06:00)  #    Comments [0] -

# Friday, October 16, 2009
Given a collection of players that were constructed like this:

private static IList<Player> LoadPlayers()
{
	Player favre = new Player { Id = 1, Name = "Favre", Team = new Team { Id = 1, Name = "Vikings" } };
	Player peterson = new Player { Id = 2, Name = "Peterson", Team = new Team { Id = 1, Name = "Vikings" } };
	Player rodgers = new Player { Id = 3, Name = "Rodgers", Team = new Team { Id = 2, Name = "Packers" } };
	Player driver = new Player { Id = 4, Name = "Driver", Team = new Team { Id = 2, Name = "Packers" } };

	List<Player> players = new List<Player> {favre, peterson, rodgers, driver};
	return players;
}

And the following LINQ query:


var query = 
	from p in LoadPlayers()
	group p by p.Team into g
	select g;

We will see the following output:


Vikings
Vikings
Packers
Packers

The reason this is happening is that we created new Team objects for each and every Player, and when LINQ tries to group, it does so based on object equality. The solution to this is to override the Equals() and GetHashCode() methods in the Team class. After doing that, the LINQ query will be able to group the objects up properly and just display each team name once. Resharper has a nice code generation template to create solid implementations of these methods (press Alt+Ins to bring up the code generation menu).

The example here is obviously contrived. We could create each team object once, and then use the same instance during the property assignment, and if we did that, things would work just fine. However, I ran into a more generalized version of this problem when using WCF and a lot of custom code generation. The underlying lesson is still the same: LINQ and GroupBy need to have object equality defined properly in order to make things work as you would expect.

Friday, October 16, 2009 1:14:18 PM (Central Daylight Time, UTC-05:00)  #    Comments [2] -
.NET | LINQ
# Monday, October 12, 2009
Since my last post, the date has changed from October 9th to October 12th. The reason this is important is that the functions that needed to calculate the date based on the current date are now coming through a different code path. Before, everything worked great. As of October 10th, not so much. The fix is simple - the getDate function was missing the parentheses to make it a method call. The fix is quite simple and is listed below:

var day = (now.getDate() < 10) ? "0" + now.getDate() : now.getDate();
Monday, October 12, 2009 11:11:13 PM (Central Daylight Time, UTC-05:00)  #    Comments [0] -
ASP.NET | ASP.NET MVC
# Thursday, October 08, 2009
I have several reports in my ASP.NET MVC application that are date-oriented. I had start date and end date text boxes, and things worked fine. What I really wanted was something that would allow those date boxes to be populated with a variety of canned date ranges (e.g. Year to Date, Last Month, etc.). I found just what I was looking for in a pure JavaScript implementation here.

The one problem I found was that "Last Month" was being calculated incorrectly. Below is the simple fix. Thanks to epalla for the original code.


// last month 
case "lastmo":
    // we need a new month variable for month-1, also formatted correctly
    var lastmonth = ((month - 1) < 10) ? "0" + (month - 1) : (month - 1);
    startbox.value = lastmonth + "/01/" + year;

    // now grab the last day of the month (30, 31? we don't know!)
    var moend = new Date(year, (month - 1), 0);
    endbox.value = lastmonth + "/" + moend.getDate() + "/" + year;

    break;
Thursday, October 08, 2009 8:44:07 PM (Central Daylight Time, UTC-05:00)  #    Comments [0] -
ASP.NET | ASP.NET MVC
# Thursday, July 09, 2009
I posted about my iPhone experience in April, 2008. I just picked up a 3gs, and I have to say that I am incredibly pleased. Just about every complaint that I had in that original article has been addressed. In addition, the speed increase really is significant. It really is that noticeable. Add in the cool camera upgrades (better pixels, video, and cool touch to focus), and this is absolutely a winner.

The current complaints deal with lack of MMS and tethering, but that's hardly Apple's fault. (Nice workaround for tethering posted here.) The experience ordering business phones through AT&T sucked as bad as anything I've ever dealt with, so it's not shocking they don't care about their users enough to enable simple features such as these.

Now I just need to find an iPhone app to follow the Tour de France. Allez!

Thursday, July 09, 2009 9:39:39 PM (Central Daylight Time, UTC-05:00)  #    Comments [0] -
Macintosh
# Sunday, May 31, 2009
Given a set up like this (where ExpenseSummaryData returns some arbitrary HTML fragment) :

<%using (Ajax.BeginForm("ExpenseSummaryData", new AjaxOptions { UpdateTargetId = "result" })) { %>
    <label for="startDate">Start Date:</label>
    <%= Html.TextBox("startDate") %>
    <br />
    <label for="endDate">End Date:</label>
    <%= Html.TextBox("endDate")%>
    <br />
    <input type="submit"/>
    <br />
    <span id="result"/>
<% } %>

If that is all your page does, you will notice that you get taken to a new page when pressing Submit. The data on the new page is the HTML fragment returned by the AJAX call, but that's all it contains (e.g. no master page), and it's clearly not replacing the result span.

The reason for this is that I forgot to add the following lines to the <head> section in the original page:


    <script src='<%=ResolveUrl("~/Content/js/MicrosoftAjax.debug.js")%>' type="text/javascript"></script>
    <script src='<%=ResolveUrl("~/Content/js/MicrosoftMvcAjax.debug.js")%>' type="text/javascript"></script>

After adding those declarations in, the content in the span tag is properly updated and it looks like a real AJAX call.

Sunday, May 31, 2009 11:38:24 AM (Central Daylight Time, UTC-05:00)  #    Comments [0] -
.NET | ASP.NET MVC
# Saturday, April 25, 2009
I've been on Facebook for a while, and I just added Twitter to the mix. I'm trying to keep communications on those sites much more informal and fairly non-technical. If you want to follow me, search for dmiser@wi.rr.com on Facebook or danmiser on Twitter. Hope to see you over there.
Saturday, April 25, 2009 12:08:10 PM (Central Daylight Time, UTC-05:00)  #    Comments [1] -
.NET
# Wednesday, April 22, 2009
Are you looking for a strong developer/architect with a serious passion for all things technical and a unique blend of experience? If so, feel free to email me. My main focus over the past couple of years has been on things ALT.NET-ish (e.g. ASP.NET MVC, NHibernate, Spring.NET, etc.) while I have delved into a variety of other technologies as well (e.g. Mindscape LightSpeed, LINQ, Dynamic Data, Delphi, etc.). If you know of an opening - contract or full-time - please keep me in mind. I'd prefer to remain in the Milwaukee area, but occasional travel wouldn't be the end of the world.

Until the next technical post here, take care and thanks in advance.

Wednesday, April 22, 2009 1:29:54 PM (Central Daylight Time, UTC-05:00)  #    Comments [0] -
.NET | ALT.NET | Delphi
# Tuesday, March 17, 2009

We ran into a problem using OpenSessionInView on an IIS7 server. It turns out that when running in IIS7's new Integrated Managed Pipeline mode, we would get this error when trying to access lazy loaded objects:


Could not initialize proxy - the owning Session was closed.

For now, we just set the Managed Pipeline mode to Classic and things work fine again. When we get time, we'll be looking to try this configuration.

Tuesday, March 17, 2009 6:47:45 PM (Central Standard Time, UTC-06:00)  #    Comments [0] -
ALT.NET
# Monday, March 16, 2009

I've listened to podcasts from http://www.twit.tv for a while now, and have always found the shows entertaining and informative. Scott Bourne just launched Managing Your Daily Life, a blog about backups, storage, and how to manage the volume of data we all have. Hopefully we get to podcasts soon. :)

Yes, this post enters me in a contest to win a Drobo, but I like the content, too!

Monday, March 16, 2009 11:21:33 AM (Central Standard Time, UTC-06:00)  #    Comments [0] -

# Thursday, March 12, 2009

The first time you load an assembly of Quartz.NET jobs, it populates the database with the current trigger information (cron vs. simple, timings, etc.) that it finds in the configuration file. It appears that this information does not get updated once it's in the database. So if you want to make a change to set the trigger time to be every minute instead of the original version of "run every day at 2am", you will be waiting for a loooong time to see that trigger fire (unless you start at 1:59am :)).

Since I'm using Migrator.NET to control my database schema, I can easily drop the tables and recreate them. This isn't a big deal because once I have things tested, I won't need to change the trigger information, but it did trip me up for a bit so I thought I'd share.

Thursday, March 12, 2009 10:47:18 PM (Central Standard Time, UTC-06:00)  #    Comments [2] -
.NET | ALT.NET
# Wednesday, March 11, 2009
I came across this exception today when inserting multiple objects through an NHibernate SessionScope:

NHibernate.NonUniqueObjectException: a different object with the same identifier value was already associated with the session: 0, of class: Foo.Entity.Bar
   at NHibernate.Impl.SessionImpl.DoSave(Object obj, Object id, IEntityPersister persister, Boolean useIdentityColumn, CascadingAction cascadeAction, Object anything)
   at NHibernate.Impl.SessionImpl.SaveWithGeneratedIdentifier(Object obj, CascadingAction action, Object anything)
   at NHibernate.Impl.SessionImpl.Save(Object obj)

I didn't see much out there on this, but Geoff Lane picked up on it pretty quickly. It turns out that my Bar.hbm.xml mapping file had set the id generator incorrectly to "generated", which was a problem because it was actually a MSSQL IDENTITY field. The mapping should have looked like this:


<id name="Id">
  <generator class="native" />
</id>

Luckily for me, I had run my tests by trying to insert 2 entities inside the session so the error bubbled up right away.

Wednesday, March 11, 2009 8:06:02 PM (Central Standard Time, UTC-06:00)  #    Comments [0] -
.NET | ALT.NET

After logging in, be sure to visit all the options under Configuration in the Admin Menu Bar above. There are 26 themes to choose from, and you can also create your own.

 

Wednesday, March 11, 2009 1:00:00 AM (Central Standard Time, UTC-06:00)  #    Comments [0] -
dasBlog
# Tuesday, March 10, 2009

Yesterday, I had to upgrade from Spring.NET 1.1 to Spring.NET 1.2 in order to use Quartz.NET. After doing that, I started to get InvalidCastException errors in my unit tests that told me I couldn't convert an int to a Nullable<int>. Things like this were broken:


void TestMe(int? id) 
{ 
  // do testing here
}

// and elsewhere, we call it like this
TestMe(42);

Very strange. It turns out that this is a known (and fixed) issue due to using Nullable types through AOP. I grabbed the latest nightly build and all of the tests passed again.

However, when running, I found a breaking change in the post-1.2.0 code that I needed to correct, namely:

Overriding the SessionFactoryObjectName in web.config no longer uses Spring.Data.NHibernate.Support.OpenSessionInViewModule.SessionFactoryObjectName as the key. Now, you need to use Spring.Data.NHibernate.Support.SessionScope.SessionFactoryObjectName. e.g.

<add key="Spring.Data.NHibernate.Support.SessionScope.SessionFactoryObjectName" 
  value="NHibernateSessionFactory" /> 

Now everything is upgraded and working again.

Tuesday, March 10, 2009 1:02:30 PM (Central Standard Time, UTC-06:00)  #    Comments [0] -
.NET | ALT.NET
# Thursday, February 26, 2009

I've been playing with ways to write a solid (and even SOLID :)) architecture with ASP.NET MVC. I started with a plain LINQ to SQL approach, and then migrated to LightSpeed, and finally ended up checking out S#arp last week. Here are my notes of pros/cons on each approach. Yes, I could (and most likely will) address some concerns by writing code for it. This is more of a laundry list of the state of things as I see them at this point in time.

LINQ to SQL

Pros

  • Visual designer

Cons

  • MS is talking about phasing LINQ to SQL out and forcing people towards Entity Framework. I'm pretty sick of chasing MS's data-access strategies around every year.
  • LINQ to SQL mostly defaults you to a 1:1 mapping between your database and your model.
  • Support for modifications to the schema sucks, to be generous.
  • No UnitOfWork concept. Of course, as I prepared this blog entry, I found this article published just today, so maybe that would address this point.

LightSpeed

Pros

  • Support is outstanding.
  • Nightly builds are available.
  • Visual designer.
  • Proven patterns bundled in their core libraries (UnitOfWork, Repository, Entity, etc.).
  • Picks up changes from the schema flawlessly.

Cons

  • Commercial and propietary.
  • Lacks quite a bit of LINQ support. For example, groupby and join are not supported. This meant that I use LINQ to SQL when I need these features. Fortunately, that's all isolated to my report module, so it's not as horrible as it could be.

S#arp

Pros

  • Open Source
  • Uses standard, widely adopted open source libraries: NHibernate, Windsor, etc.
  • Convention over Configuration
  • Scaffolding

Cons

  • I'm not digging the T4 templating mechanism. They conflict with VisualSVN and Developer Express tools, and having to write a template for each and every entity is cumbersome.
  • No visual designer
  • No ability to import entities from an existing database. Yes, they like DDD, but in almost every project I've been a part of, the database is the thing that already exists.
  • No UnitOfWork pattern (I might be able to fit code out there that does this in with S#arp). The [Transaction] attribute approach feels a bit dirty.
  • The scaffolding is a bit too simple. It doesn't build up object graphs with links (for display) or SelectLists (for editing). Yes, I can add that. It probably will get that functionality at some point, too. But it doesn't do it right now.

For now, I think I'll be staying with LightSpeed, but I'll be watching S#arp very carefully.

Thursday, February 26, 2009 3:17:53 PM (Central Standard Time, UTC-06:00)  #    Comments [0] -
ASP.NET MVC
# Tuesday, February 17, 2009

Ages ago, I wrote about my search for a file sharing application. I eventually went with BeInSync, and used it quite a bit over the past 18 months or so. However, they haven't updated it recently, and there are problems when editing Excel spreadsheets inside the shared folder (I told BeInSync about this problem, they fixed it, and then broke it in the last release). All in all, it was just showing it's age.

Armed with a new set of fairly light requirements (Mac/Windows support, permissions, auto-sync that doesn't fail), I evaluated the space again and came out with a very positive experience of DropBox. It works very well between Mac and Windows, has an awesome web interface, and hasn't exhibited any lags or slowness. In addition, it has the ability to revert to previous versions of documents, which is a nice feature that all developers have come to appreciate.

I'd like to see a couple features in the near future (native iPhone app with support for iWork documents, ability to set your own private key), but this thing was dead simple to install and use, and has worked brilliantly for the past month with a small group of people.

Tuesday, February 17, 2009 1:45:12 PM (Central Standard Time, UTC-06:00)  #    Comments [0] -
Macintosh
# Monday, February 02, 2009

I'm using SqlBulkCopy to quickly copy an Excel spreadsheet into MSSQL. It is lightning fast, and works extremely well. One snag came up because I need to have an Identity field for my primary key on this newly copied table (the short story is NHibernate's need for a PK, and the lack of anything resembling a PK in the Excel data due to it coming from legacy data).

The problem is if you add the Identity field in the first column of the destination table, SqlBulkCopy will try to line the columns up by position and things break. You can add ColumnMappings to have SqlBulkCopy write the excel columns to the right MSSQL table column, but that can be a lot of code if you have a lot of columns.

My solution ended up being to simply add the Identity field to the end of the destination table. By doing that, the columns line up during the SqlBulkCopy and everything works just fine.

Monday, February 02, 2009 10:13:23 PM (Central Standard Time, UTC-06:00)  #    Comments [0] -
ADO.NET
# Friday, January 30, 2009

At work, a debate broke out over MVC. In that debate, Chris Peterson commented that he hated the way things looked on the view pages, specifically with code executing in the view context. By way of example, he talked about the need for a for loop to display a collection, and how he didn't like that. Geoff Lane commented that Grails had support for this built-in.

To overcome these objections, I wrote the following simple extension method:

public static class RenderPartialCollectionExtension

{

    public static void RenderPartialCollection<T>(this HtmlHelper htmlHelper, string partialViewName, IList<T> list)

    {

        foreach (T item in list)

        {

            htmlHelper.RenderPartial(partialViewName, item);

        }

    }

}

This means that instead of the old-style View page code, like this:

<%

   foreach (Foo foo in Model)

   {

       Html.RenderPartial("~/Partials/DisplayFoo.aspx", foo);

   }

 %>

You can just write code like this:

<% Html.RenderPartialCollection<Foo>("~/Partials/DisplayFoo.aspx", Model); %>

Friday, January 30, 2009 4:40:58 PM (Central Standard Time, UTC-06:00)  #    Comments [1] -
ASP.NET MVC
# Thursday, January 29, 2009

It seems that ASP.NET MVC doesn't allow for strongly-typed partial views. If anyone knows of a clean way to do it, I'd love to know!

Take the following typical page declaration:

<%@ Page Language="C#" Inherits="System.Web.Mvc.ViewPage<Foo>" %>

This declaration allows us to access the Foo.Bar property in the view page using the following syntax: Model.Bar. This works really well, and we even get Intellisense for Foo when accessing the Model property in the editor. In contrast, if we inherited from the non-generic ViewPage, Model becomes a simple object type, which means type-casting to get to our passed in model object.

However, using partial pages with a similar technique does not work. For example, if we have a partial page (ViewPage or ViewUserControl) and call it like below, it will not allow for strong typing of the page:

Html.RenderPartial("DisplayFoo", foo)
If we try to strongly type the page, it will result in an error like this at run-time:
Parser Error Message: Could not load type 'System.Web.Mvc.ViewPage'.

One work-around is to create a code-behind file, and specify the strong typing there, and then inherit the partial page from the code-behind. But I really don't like that. RC1 made great strides to get rid of the code-behind mess, and I would prefer not to reintroduce it just for this.

Update: Thanks to bradleylandis in the ASP.NET MVC forum, he correctly figured out that I had my partial page in a folder other than the Views folder. He mentioned that you need to copy the web.config file from the Views folder to any folder that you serve view pages out of. After doing that, I now have a strongly typed partial page.

Thursday, January 29, 2009 1:22:09 PM (Central Standard Time, UTC-06:00)  #    Comments [0] -
ASP.NET MVC
# Wednesday, January 28, 2009

There were a few changes between ASP.NET MVC Beta and RC1 regarding list binding. For background on list binding, look at Phil Haack's excellent article. Here are the changes that I saw, some good, and some bad:

  • You no longer need to specify the ".index" hidden field. This is good, as it's one less hidden field to take care of.
  • Binding occurs automatically for lists of complex types, but you must have contiguous numbering of the elements, starting with zero. This means that you can no longer specify the index with things like key information. I'm not wild about this change.
  • In the Beta release, binding would only occur for properties of IList. I've been using LightSpeed lately, and that means my property looks like this: EntityCollection<FooType> FooProperty. EntityCollection supports IList, but because it wasn't truly an IList in the class declaration, the default binding didn't work. In the Beta release, I got around this by adding a mirrored property of IList<FooType> and then copying the data over to FooProperty in my controller method.
  • Nested property references, e.g. Foo.Bar, now get the resulting input id renamed to Foo_Bar. This makes it easier to work with jQuery selectors on these elements.

All in all, I'm really liking the RC1 release. I'm looking forward to the release!

Wednesday, January 28, 2009 6:04:53 PM (Central Standard Time, UTC-06:00)  #    Comments [1] -
ASP.NET
# Thursday, October 02, 2008

I'll be out in L.A. for PDC 10/25-10/30. If you're going to be there, too, drop me an email!

Thursday, October 02, 2008 10:22:41 AM (Central Daylight Time, UTC-05:00)  #    Comments [0] -
.NET
# Monday, September 29, 2008

Please RSVP to dmiser@wi.rr.com ASAP if you plan on making this Wednesday's ALT.NET meeting, where we can hopefully cover mocking.

When: 10/1/08 @ 7pm

Where: 10000 Innovation Drive, Suite 260 (SpiderLogic office)
Monday, September 29, 2008 9:58:05 AM (Central Daylight Time, UTC-05:00)  #    Comments [0] -
ALT.NET
# Wednesday, September 03, 2008

Due to lack of responses, I'm canceling the ALT.NET meeting for tonight. Please mark your calendars for Wednesday, 10/1/08 for the next meeting, where we will try to cover mocking.

 

Please send me an email at dmiser@distribucon.com if you plan on making it in October.

Wednesday, September 03, 2008 11:19:19 AM (Central Daylight Time, UTC-05:00)  #    Comments [1] -
ALT.NET
# Wednesday, August 27, 2008

Now that summer is drawing to a close, it's time to think about a meeting of the Milwaukee ALT.NET minds again.

When: Wednesday, September 3rd, 2008 @ 7pm
Where: 10000 Innovation Drive, Suite 260 (SpiderLogic office)

I'm hoping that the topic will be mocking, but I'm open to other suggestions.

If you can RSVP by sending an email to me at dmiser@distribucon.com, I'd appreciate it. That way, we can start to get a handle on head count and have enough food on hand for everyone. Thanks, and hope to see you there.

Wednesday, August 27, 2008 11:27:43 AM (Central Daylight Time, UTC-05:00)  #    Comments [0] -
ALT.NET
# Friday, May 16, 2008
When deploying an ASP.NET web site to IIS 6 on a Windows 2003 server, you may encounter 404 errors when trying to access the aspx pages. The quick solution is to Allow ASP.NET extenstions from the IIS Admin Web Service Extensions node. Neil Kilbride has a much more comprehensive writeup on this here.
Friday, May 16, 2008 9:38:13 AM (Central Daylight Time, UTC-05:00)  #    Comments [1] -
ASP.NET
# Wednesday, May 07, 2008
Sorry for the late notice, but we're going to have to cancel the ALT.NET meeting for this month. We'll get things geared up again for next month.
Wednesday, May 07, 2008 12:32:48 PM (Central Daylight Time, UTC-05:00)  #    Comments [2] -
ALT.NET
# Tuesday, April 15, 2008

If you want to add Membership Provider features to your WebHost4Life application, I've found that you can't use the aspnet_regsql wizard UI. Instead, use the following code at the command prompt:


aspnet_regsql -C "Data Source=sqlNNN.mysite4now.com;Initial Catalog=yourdb;User Id=yourUserName;Password=yourPwd" -A mr

Replace NNN with your assigned address, and obviously replace the other elements of the above connection string, too. :-)

Tuesday, April 15, 2008 4:12:01 PM (Central Daylight Time, UTC-05:00)  #    Comments [0] -
.NET | ASP.NET
# Monday, April 14, 2008

At the risk of having my Apple fanboy status revoked, I have to say that I find the iPhone lacking. It seems that Apple has released a half-finished product upon the masses, and the masses have spoken in hypnotized unison that they think Apple can do no wrong. Oh, sure, I was seduced at first. Visual voicemail is pretty cool. The flicking and gesturing for the UI is even wicked hot. In short, the attention to detail on the things that are implemented are first-class.

So why the negative finding? Sure, most, if not all, of these things are fairly well-known, but they do impact my day to day life.

  • I have a Motorola S9 headset that doesn't work with the iPhone. Sure, phone calls can come through, but not music. Requiring an AD2P Bluetooth adapter is just plain stupid, given that the iPhone is supposed to be the pinnacle of form and function. Sorry, no. It gets a miserable failing grade.
  • How is it that a device manufactured in 2007/2008 could come without cut/copy/paste?
  • No speed-dial. I might be safe in saying that every phone on this planet, with the possible exception of 1950s rotary dial phones, has the capability to speed dial by pressing one button. Not so for the iPhone!
  • Ok, maybe speed-dialing is so 1999, and we don't need it because the iPhone is a full-fledged multimedia experience. Fine theory, but the reality is you can't even do voice dialing! Let me take my Bluetooth headset (but not my Motorola S9!!), and - wait, I can't actually do anything with it. I need
    to take my iPhone out of my pocket, press like 4 things, and THEN I can start a conversation. I wonder if that will comply with all of those laws requiring hands-free cell phone use popping up all over the nation.
  • The fact that I need to buy extra accessories to get my iPhone to work. The headphone jack was recessed for that full-flush feeling. My existing mini-RCA jack doesn't let me keep continuous playback, my Griffin FM transmitter turns my phone off, and my headphone Y-splitter isn't deep enough. At least my USB charger works.
  • The World Clock doesn't allow you to add cities. It wouldn't be a big deal to add the exact city you want if we could actually access the underlying OS files.
  • I'd like a much better user experience to sort, filter, and search my contacts. Using the Categories I've already assigned would be a good start. Maybe I'm just missing something here.
  • No ToDo list, nor integration to any GTD system, or any system for that matter. Which brings us to...
  • The Missing SDK. It's late. I don't know what to expect here, and I think Apple prefers it that way. I'll leave out the glaringly obvious fact that the SDK should have been released on Day 1. Oops. I guess I won't. :-)

I'll be working hard over the next couple of weeks to try to remedy the list above, and if I make any significant progress, I'll be sure to post here. Feel free to comment if you have any suggestions.

Monday, April 14, 2008 9:13:01 AM (Central Daylight Time, UTC-05:00)  #    Comments [3] -
Macintosh
# Wednesday, March 26, 2008
Here's a quick linkblog post because I needed to copy some files from my local drive to a remote desktop computer, and this blog entry spelled it out quite effectively.
Wednesday, March 26, 2008 11:57:51 AM (Central Standard Time, UTC-06:00)  #    Comments [1] -

# Tuesday, March 25, 2008

Problem: I have written my own membership provider to store and validate user information. Further, I have a web page that allows a user to come and sign up with a username, password, and a whole host of other client-related data. When the user submits that data, I would like to have them logged in.

Solution: Since I'm using Forms authentication for the ASP.NET website, it appears that the following code-snippet does what I want:

if (Membership.ValidateUser(u.UserName, u.Password))
    FormsAuthentication.SetAuthCookie(u.UserName, false); 
Tuesday, March 25, 2008 2:24:17 PM (Central Standard Time, UTC-06:00)  #    Comments [0] -
.NET | ASP.NET
# Monday, March 17, 2008

Nikhil Kothari wrote a brilliant blog post titled Ajax with the ASP.NET MVC Framework. In that post, he built a demonstration TaskList application that used Ajax and the ASP.NET MVC framework that Microsoft is working on. Microsoft is doing a good job in releasing more frequent updates to this framework, but that means that there will be pain when moving from one release to the next. The ASP.NET MVC Preview 2 release was no exception to this rule. There were a list of documented, tedious and manual steps that one needed to follow to get their old code running with preview 2: update web.config, change the route description, update assembly dependencies, etc.. There were also other items that were not so well-documented:  add ProjectTypeGuids to the csproj file, methods that fell out of the preview 2 release (e.g. ViewFactory.CreateView), etc.

I updated Nikhil's code, and some basic testing shows me that it's working with the preview 2 bits. Download the updated code here. Please leave a comment or send me an email if you see any errors that need to be corrected.

Monday, March 17, 2008 12:21:14 PM (Central Standard Time, UTC-06:00)  #    Comments [0] -
.NET | ALT.NET
# Friday, March 07, 2008

ASP.NET MVC Preview 2 was released yesterday. I've had a chance to install and play with it, and I hate to report that I am underwhelmed. My thinking leads me to believe that MS rushed this release out the door just to be able to say they shipped something at MIX. While there has been good progress made on several issues (e.g. medium-trust support, public methods are callable by default, and route setup is improved). However, I find several other things lacking, referenced from ScottGu:

  1. Source code is not released. Sure, it might be coming "soon", but why not have everything coordinated and ready to go? Hitting an arbitrary deadline of "ship while at MIX" is less important to me than having answers to questions like these.
  2. Dynamic Data (scaffolding) will not work with Preview 2. It is almost always inexcusable to take functionality and features away. The ability to scaffold is one of the coolest things in Rails. Having something similar in ASP.NET was a welcome treat. Now it's gone. Again, I'm sure there is something that will be released "soon", but why not have everything ready to go? I hate not only playing catch up years later, but having a taste of it, only to have it yanked a few weeks later.
  3. The "choose your unit testing framework" feature that was hyped up ships with only MSTest enabled. I understand that MS is working to enlist support from the various unit testing groups to add their tool to the list, but it seems disingenuous to post mocked up screen shots with test frameworks in a combo box that were never developed.
  4. Others have pointed out some more detailed issues that need solving to help with testability (e.g. see here and here).

I look forward to seeing these issues addressed ASAP because I absolutely LOVE the promise that the MVC bits hold.

Friday, March 07, 2008 1:30:33 PM (Central Standard Time, UTC-06:00)  #    Comments [0] -
.NET | ALT.NET | ASP.NET
# Thursday, March 06, 2008

All in all, I was very pleased with the inaugural meeting of the Milwaukee ALT.NET group. We had a turnout of 10 people, which exceeded my expectation in quantity, and the quality was quite good, too. We talked about general architecture topics for about 45 minutes, and then Todd Penland led the group in discussion on persistence and the Unit of Work pattern. We talked about various alternatives to building this yourself (e.g. NHibernate), and talked about the pros and cons of this approach (i.e. requiring a topological sort to deal with database changes properly (something near and dear to my heart from when I was writing code for MIDAS/DataSnap and BDP), handling object graphs, requiring a MarkDirty() call in the property setters, etc.). It was a very engaging discussion. Thanks to everyone who showed up, and to SpiderLogic for providing the refreshments.

Here are the details for next month:

When: Wednesday, April 9, 2008 @ 7pm
Where: 10000 Innovation Drive, Suite 260 (SpiderLogic office)
What: Dan Piessens (who is on the advisory panel for Unity and EntLib 4.0) will cover Unity and EntLib 4.0

I'm looking forward to it, and hope you are, too. If you're planning on being there, please send me an email to dmiser@distribucon.com, or leave a comment here. That way I can plan the food and refreshments accordingly. Feel free to drop me a line on topics you'd like to see covered, too.

Updated to change the date to April 9th. This date change will allow us to hopefully get more exposure thanks to Scott Isaacs and the WI .NET User Group. Thanks, Scott!

Thursday, March 06, 2008 10:35:55 AM (Central Standard Time, UTC-06:00)  #    Comments [1] -
.NET | ALT.NET
# Monday, February 25, 2008

A co-worker of mine, Brian Kapellusch, is working on a web framework to give us a garden path for ASP.NET applications. The code that he's writing (and the code to use it) is trés elegant. One of the underpinnings of this framework is his use of the ObjectDataSource class (ODS). I am making heavy use of NHibernate and Spring.NET in this application as well. My understanding of the ODS told me that if I wanted to control how the source object was created, that I simply needed to handle the ObejctCreating event and assign the desired object instance in that event to e.ObjectInstance (see here for some more usage examples).

However, it turns out that is not enough to fully control when an object gets created. If you set the TypeName property to a concrete class, ODS will also create a new object behind the scenes - even if you have handled the ObjectCreating event. This becomes very problematic when using an IoC container to automatically build up and inject properties into your class.

The bottom line is this: If you see one version of your object that has things built up properly (because the IoC container was used properly), and one version that has null properties (because, in essence, ODS called "new MyClass()" for you, which doesn't let the IoC container do it's job), you should change the TypeName to point to the interface type instead of the concrete class type. Much thanks to Brian for this one.

Monday, February 25, 2008 6:36:54 PM (Central Standard Time, UTC-06:00)  #    Comments [1] -
.NET | ALT.NET
# Wednesday, February 13, 2008

On my desktop machine, I have a dual monitor setup with 2 19" monitors and an ATI Radeon graphic card running each monitor at 1152x864. This setup has worked flawlessly for me for a couple of years. Recently, though, my primary monitor has been acting up. When I first boot up, I need to move my mouse, which then "scrolls" the viewable area. It's like I have a virtual desktop with the size of my monitor set too small for the resolution at which I'm running.

I dug around on the Display Properties' Advanced setup and went to my video card's control center. There, I noticed the EDID settings were claiming the maximum resolution of the monitor was 1024x768. That would explain this behavior. I disabled EDID for the problem monitor and set the value to the proper resolution (1600x1200). Everything is working great again.

Wednesday, February 13, 2008 9:57:49 AM (Central Standard Time, UTC-06:00)  #    Comments [0] -

# Wednesday, February 06, 2008

I'm returning to the Team in Training program this year - a little healthier, a little lighter, and a whole lot happier knowing that we all helped make a difference for the Leukemia & Lymphoma Society last year. (See here for a picture of me at the top of the last major climb last year.) I feel very blessed to have made a lot of good friends last year, all of whom have a shared passion to help out such an important cause. It must have been worthwhile, because here I go again! :-)

I've committed to raise a minimum of $4,200 for the Leukemia Society. By donating your money, you get a tax deductible donation, and also help an organization provide support to patients and research a cure. The easiest way to donate is to donate online by going to my fund-raising web page at http://www.active.com/donate/tntwi/tntwiDMiser1. Many strides have been made - partly as a result of the nearly $1 billion raised by Team In Training - but there is more to be done.

I am riding in honor of this year's beneficiary, Jesus Vega Ramos. I am also riding in memory of Lewis Challoner. Lewis was the father of my best friend, Steve, and he took us on some century rides (the Rock 100) when we were in high school. He continued to be heavily involved in the biking community, with patents granted on bikes to help the disabled, in addition to being an avid and hard-core rider of long distances into his 60s. Lewis was like a second father to me.

If you want/need to send a check, or have any other questions, please feel free to email me. Thanks for your time, and I look forward to your donation. If you know of anyone else that might like to help, please pass this on. Every little bit helps!

Wednesday, February 06, 2008 9:00:18 AM (Central Standard Time, UTC-06:00)  #    Comments [0] -

# Tuesday, February 05, 2008
I'm using NHibernate a lot more lately, and it's been working great. One of the downsides, though, is the fact that you need to build up the mapping files by hand. Well, no more. I stumbled upon the open source project, active-record-gen, on Google Code. One of the templates that it provides is one that will generate NHibernate mapping files for tables in an MSSQL database. I tried this on a couple of databases and it works rather well.

A few small suggestions:

  • Implement a better pluralization/singularization strategy by using Inflector.NET.
  • Work with more databases than just MSSQL.
  • Allow for the connection string to be built up with more options. Right now, it requires SSPI integration, and attached databases don't work as well as they should. See here for more details.
Tuesday, February 05, 2008 7:57:18 AM (Central Standard Time, UTC-06:00)  #    Comments [0] -
.NET | ALT.NET
# Monday, February 04, 2008

This link explains the unit testing tools available in VS.NET 2008 Professional. My take after reading that section is that Microsoft doesn't get it. Here is my list of observations about this section. Feel free to leave a comment to tell me where I'm wrong.

  • I feel like this is nothing more than an upsell to get me to go and buy VS.NET TeamSystem. Sorry, that's not going to happen. TeamSystem is way too expensive (both initially and in setup/maintenance time for a TFS server). Besides, we have an existing development infrastructure setup since we use multiple (non-MS) languages/platforms here.
  • It looks like MS wants to ignore the thriving and long-standing community of open source unit testing tools. I'm willing to bet that NUnit (and MbUnit, etc.) has more code using it than Microsoft.VisualStudio.TestTools.UnitTesting. Yet, if I want to use the integrated Test menu in VS.NET, I need to rewrite my unit test code to use near-identical attributes for my unit tests (e.g. [TestMethod()] vs. [Test]).
  • Code coverage is not available in VS.NET Pro. I guess code coverage isn't something that developers should be doing - well, unless they shell out tons of money to get it done. Thankfully, there are free alternatives, with cheap upgrades to the latest version.
  • I want to easily run and debug my unit tests. I know Resharper can do this, but I haven't installed that in VS.NET 2008 due to the number of issues I had with it. (Yes, I know an EAP is coming out soon, but I also have CodeRush and Refactor, which work fine with 2008.) I like TestDriven.net,  but I'd like to be sure that it doesn't go away.
  • The documentation is too cluttered. If you're going to give me a list of what's included and what's not included in the Pro version, then why not just separate the documentation to make it easier for me to see what capabilities I have (and what I don't).

In short, it's disappointing that MS has chosen to force people to one specific way of writing unit tests that is against industry norms. ASP.NET has shown me that they do understand the provider model, so why not use it here to allow me to run and debug my unit tests using whatever tools I want.

Monday, February 04, 2008 11:01:31 AM (Central Standard Time, UTC-06:00)  #    Comments [5] -
.NET
# Friday, February 01, 2008

I would like to take it upon myself to announce the formation of the Milwaukee chapter of the ALT.NET UserGroup. It will meet the first Wednesday of every month, with the first meeting to take place on 3/5/08 @ 7pm at 10000 Innovation Drive, Milwaukee, WI. Pizza and drinks will be served, and the event will be free to attend. Thanks to SpiderLogic for sponsoring the first meeting.

This group will cover agile development tools and techniques with .NET, best practices for architecture and coding, emerging technologies, and anything else the group decides to cover. For more backstory on ALT.NET, read this post. The use group will be a very participant-driven group. I will not look to lead this group in any significant way, other than to call this group to order, and get people involved in sustaining it. I've learned from other user groups that if a group is too dependent upon one person, it is a matter of time before it fails.

For the first meeting's agenda, I propose we get some volunteers to take on some minimum responsibilities and then break into an OpenSpaces format, where technical topics will be presented by anyone who wants to present. I don't want this to be yet another 1-way presentation medium for 1-2 hour topics, so be prepared to be engaged, discuss, and share (bring your laptop to showcase code and/or slides). I'll take a swipe at talking about ASP.NET MVC this first meeting. If you have something you want to see covered, or especially if you want to cover something, post a comment, and we'll get it on the agenda.

Please pass this notice around to anyone you think will be interested! If you plan on attending, I would appreciate either a comment on this blog or email to dmiser@distribucon.com, just so we can gauge how much food and drink to have on hand. I am really excited about this, and look forward to seeing everyone there!!

Friday, February 01, 2008 3:46:14 PM (Central Standard Time, UTC-06:00)  #    Comments [4] -
.NET | ALT.NET
# Tuesday, January 29, 2008

I have a .NET application that generates an XML file via serialization (through XmlTextWriter) and submits the data via https. Recently, they changed something on their end to only accept an upper cased UTF-8 encoding, like this:


<?xml version="1.0" encoding="UTF-8"?>

Unfortunately, using the .NET classes mentioned above, it generates the encoding string in lower case. I could find one mention of this on google, and they said to have the other company change (not an option here), or override XmlTextWriter. I went with that approach, making heavy use of Reflector along the way. I started by looking at the WriteStartDocument method, but realized that the private StartDocument is the thing that generates the output. It also gets called by the overloaded WriteStartDocument, so I'd need to override that method, too. However, in the private StartDocument method, it uses a bunch of private variables and generates output via another private method, InternalWriteProcessingInstructions. Ugly. At this point I realize that XmlTextWriter is not a class made for inheriting.

Back to Reflector, and I notice that the Encoding.WebName is the property used to write out the encoding string. I now create a descendant class of UTF8Encoding. The class is listed below. Now I just call XmlTextWriter, passing in UpperCaseUTF8Encoding.UpperCaseUTF8 for the Encoding type, and everything works perfectly.

    public class UpperCaseUTF8Encoding : UTF8Encoding
    {
        public override string WebName
        {
            get { return base.WebName.ToUpper(); }
        }

        public static UpperCaseUTF8Encoding UpperCaseUTF8
        {
            get
            {
                if (upperCaseUtf8Encoding == null)
                    upperCaseUtf8Encoding = new UpperCaseUTF8Encoding();
                return upperCaseUtf8Encoding;
            }
        }

        private static UpperCaseUTF8Encoding upperCaseUtf8Encoding = null;
    }
# Friday, January 25, 2008

I went in search of an application that would synchronize my bookmarks. It needed to meet the following minimum specifications:

  • Sync between Windows and Macintosh
  • Sync bookmarks between IE, Mozilla, and Safari
  • Sync between machines
  • Automatic synchronization. If I have to perform a manual step, I'm not interested.
  • Could not be an Internet-only bookmark storage service
  • Good conflict detection and resolution

Sync2It met all of those requirements, and after using it for a couple of weeks with no real major issues, I bought it. Diigo and Google bookmarks were very good applications, too, but didn't pass some portion of my needs. I did email the author about some enhancements I'd like to see to make Sync2It even better. I'd encourage you to try and buy Sync2It. That way, maybe these suggestions have a chance of getting implemented. :-)

  • While the Mac download doesn't say it, it does appear to work with Leopard.
  • The Mac version only syncs with IE and Safari. We need Mozilla support on this platform.
  • Provide an easy way to auto-launch the Sync2It application as a daemon when logging in.
  • We need to be certain that Safari 3 is supported (both on Mac and Windows).
  • It would be nice to have some kind of log to see the actual activity of a given sync.

Here's hoping this will let me focus on saving and categorizing bookmarks, as opposed to constantly leaving stray bookmarks around and needing that one bookmark on the one machine I'm not currently using!

Friday, January 25, 2008 3:43:44 PM (Central Standard Time, UTC-06:00)  #    Comments [1] -

# Thursday, January 24, 2008

I had a need to move some VB.NET code to C# today. We're still not at the point where we can just mix and match languages within an assembly, and in this case, it would be more work than I wanted to separate things out. I looked around the net, and the best code converter that I found (read: it successfully converted everything I threw at it, where others failed) was this one.

Thursday, January 24, 2008 9:36:42 AM (Central Standard Time, UTC-06:00)  #    Comments [3] -
.NET
# Wednesday, January 23, 2008

I needed to put 2 test assemblies into my automated CruiseControl.NET build and get coverage results. It appears that this is a pretty common need, with some tricks to get things working properly. According to http://www.kiwidude.com/blog/2006/10/ncoverexplorer-merging-ncover-reports.html, you need to either use an NUnit project file to contain all of the unit tests or merge the coverage xml files in the NCoverExplorer task.

NUnit project setup and problems

By using an NUnit project file, all of the tests are executed within one call, which produces one coverage.xml file. This allows tests from multiple test assemblies to be merged together into one coverage file that NCoverExplorer will understand automatically.

<TestAssemblies Include="MyApp.Tests.nunit" />

MyApp.Tests.nunit contents:

<NUnitProject>
  <Config name="Default" binpathtype="Auto">
    <assembly path="MyApp.DAL.Test\bin\Debug\MyApp.DAL.Test.dll" />
    <assembly path="MyApp.Service.Test\bin\Debug\MyApp.Service.Test.dll" />
  </Config>
</NUnitProject> 

The major downside of this approach is that, according to http://nunit.com/blogs/?p=9,  when using the NUnit project file, the config file that gets loaded needs to be based off of the NUnit project filename (i.e. in this case, MyAppT.Tests.config) and not the individual test assembly filenames. This means that we need to continually merge all of the app.config files into one "master" config file. This is not exactly a long-term, maintainable solution.

NCoverExplorer task setup

That brings us to the second possible solution presented above, namely to merge multiple coverage files together. To do this, you need to take some care in how you set the properties up for the tasks so that you don't overwrite coverage output files. My current build project looks similar to the one below. One other thing to keep in mind is to include the *.CoverageMerge.xml file in your CC.NET config file's <merge> section for this project.

<ItemGroup>
  <TestAssemblies Include="$(DALTestAssembly)" />
  <TestAssemblies Include="$(ServiceTestAssembly)" /> 
  <NCoverAssemblies Include="$(DALAssembly)" />
  <NCoverAssemblies Include="$(ServiceAssembly)" />
  <NCoverCoverageFiles Include="**.Coverage.xml" />
</ItemGroup>

<Target Name="Test" DependsOnTargets="CoreBuild">
  <NCover ToolPath="lib\NCover\"
    CommandLineArgs="%(TestAssemblies.FullPath) /xml=%(TestAssemblies.Filename).xml /labels /nologo"
    CommandLineExe="lib\NUnit\nunit-console.exe"
    CoverageFile="%(TestAssemblies.Filename).Coverage.xml"     
    LogFile="%(TestAssemblies.Filename).Coverage.log"
    LogLevel="Verbose"
    WorkingDirectory="$(MSBuildProjectDirectory)"
    Assemblies="@(NCoverAssemblies)"
  />

  <NCoverExplorer
    ProjectName="MyApp"
    ReportType="ModuleClassSummary"
    OutputDir="$(MSBuildProjectDirectory)"
    XmlReportName="MyApp.CoverageSummary.xml"
    HtmlReportName="MyApp.CoverageSummary.html"
    ShowExcluded="True"
    SatisfactoryCoverage="80"
    CoverageFiles="@(NCoverCoverageFiles)"
    MergeFileName="MyApp.CoverageMerge.xml"
    ToolPath="lib\NCover\Explorer"
  />
</Target>
Wednesday, January 23, 2008 9:44:21 AM (Central Standard Time, UTC-06:00)  #    Comments [0] -

# Friday, January 11, 2008

To be sure, this is an incomplete list, but it is a good start. Here's what I don't like about LINQ to SQL:

  • It only works with MSSQL. Yes, this point has been beaten to death, but it is entirely justified. Third party solutions don't cut it. LINQ to SQL intentionally seeks to exclude a sizeable population because of this hair-brained decision.
  • No way to easily specify adhoc LINQ queries. This doesn't count. I know the benefits of design-time queries, but I should also be allowed to shoot myself to get the added flexibility if I so choose. Building up expression trees is not a viable option for every day development.
  • The constant labeling of LINQ to SQL as an OR/M. That label considerably overstates what this technology does. One to one mapping between a table and a class is not really OR/M. It seems like they want to force you to change your database by writing stored procs and views to make your object model better.
  • There is no automated way to easily pick up changes to the database schema.
  • There is no easy way to preserve changes to the generated code. e.g. I change the name of the automatically generated class from collection_details to CollectionDetails, but I evolve the schema of the table. When I re-add the table, I need to set all of the custom properties again. I know I shouldn't change generated code, but see the next point.
  • Speaking of collection_details, it would be much better if the underlying class generator had some options to clean up legacy table names (e.g. remove underscores, camel case resulting table and column names).
  • No many-to-many support. In short, when you have an junction table (aka associative table or cross-reference table), you will need to write code like this: User.UserPermissions[0].Permission vs. User.Permissions[0]. Until we see LINQ to Entity (if ever), we do have this, but you can't use the new entity in a LINQ query.
  • There is no built-in solution to using LINQ across tiers. I don't want to expose my LINQ classes (see the point above about the tight coupling between database and objects) as I may want to change my database, and I don't want that cascading to all of the places that use it. There is also no diffgram, so even if I did it, I would have to write my own change tracking and resolving support. I went to an OpenSpaces meeting on this very topic during CodeMash, and the consensus was not flattering.

In short, it seems like this part of LINQ was released way before it was ready. But it does demo well...

Feel free to add your own grievance to the comments.

Friday, January 11, 2008 12:23:26 PM (Central Standard Time, UTC-06:00)  #    Comments [5] -
.NET | LINQ
# Tuesday, January 08, 2008

I have a PATH that is miles long, and I needed to find out where a certain application was launching from. On a good operating system, this kind of functionality is built in. :-) On a Windows operating system, you can create a BAT file, or download a utility.

Tuesday, January 08, 2008 3:42:36 PM (Central Standard Time, UTC-06:00)  #    Comments [6] -

# Sunday, December 30, 2007

I have been reading Dustin Campbell's series, The 12 Days of Refactor! X-mas, with interest. He's a very good writer, and has broken down a bunch of Developer Express features into easy to digest chunks of information.

The episode I linked to above touched on the XML Literal support that shipped with VB in Visual Studio 2008. The one sentence summary of this technology is that it lets the VB compiler translate raw XML in the source code into strongly-typed code using XML classes under the hood. It's a very nice idea, and I encourage you to look at the links to learn a little more about it.

While the VB team thought this was a good idea and added the feature, Anders and the C# team believed that it was superfluous to add such a thing to the C# side. I haven't really made up my mind which group I side with yet. However, Anders is benevolent :-), so he gave us the little-documented PasteXmlAsLinq addin that will take XML on the clipboard and paste it into a file in C# syntax building the XML up using classes like XElement.

In a default install of VS2008, open C:\Program Files\Microsoft Visual Studio 9.0\Samples\1033\CSharpSamples.zip and extract the LinqSamples\PasteXmlAsLinq files. There is a Readme.html file in there that tells you how to build, install and use the addin.

While this isn't the same as VB's support for XML Literals, it does make things easier to work with.

Sunday, December 30, 2007 5:02:25 PM (Central Standard Time, UTC-06:00)  #    Comments [1] -
.NET | LINQ | XML
# Friday, December 14, 2007

Things I learned this week (sorry, Carl!):

  • The Cisco VPN Client software is very fickle. In order to upgrade from 4.8 to 5.0, you need to uninstall and install, with reboots to be found everywhere.
  • Installing an entire slew of MS updates is usually a good idea to keep your system up to date.
  • Even though your computer works fine at home, you can't rely on it working the same way when you get to work. For example, you might have internet access at home with no problems, but when you get to work, traffic over port 80 will suddenly stop about 5 minutes from the time you power up. https, ftp, email, IM, and everything else will continue to work just fine. Just no http traffic over port 80.
  • 5 minutes is not a lot of time to conduct google searches to find out what's wrong.
  • MS System Restore is implemented about as horribly as anything I've ever seen.
  • After running System Restore, the problem does not go away.
  • To make matters worse, System Restore totally hosed my Office install where it deleted a bunch of files from MSOCache, thereby causing my Office products to not be able to launch properly, or even uninstall.
  • After copying missing files back to MSOCache, all of the Office applications claimed they needed to repair installs upon launch. Every time.
  • MS has really good directions for how to manually uninstall Office 2007.
  • Seconds before doing a complete wipe of your system, it's a good thing to double check with friends who have Google-Fu.
  • It turns out that c:\windows\system32 has 2 files: vsdatant.dll and vsdatant.sys. These files get linked with ZoneAlarm a lot in google searches, but they are also used by the Cisco VPN Client. Something in the Cisco (un)installer caused rogue versions of these files to be left in my system. Rebooting to Safe Mode to clean these files up (along with the registry entries) finally got things back to normal.

And that, my friends, is what I learned this week. Now where's that next Monday's episode?!?

Friday, December 14, 2007 9:38:47 AM (Central Standard Time, UTC-06:00)  #    Comments [1] -

# Monday, December 10, 2007

At the risk of another "Me, too!" post, I thought I'd highlight several links that I have found to be helpful, and for a value-added bonus, talk about why this release matters to me. Back in the day (oh boy, does that make me sound old!), I learned how to program for the Internet by using straight HTML and Delphi to create CGI and ISAPI extensions. In order to do this, you needed to be quite aware of how the actual protocols worked, and what to do to make things behave as you'd expect. I stayed with web development up until I was using COM objects (again, written in Delphi) from an ASP page. After that, I wasn't into the web development scene much on a full-time basis.

ASP.NET 1.0 and 2.0 came along, and I found them to be quite daunting. It seemed as if it was framework built upon framework, layered with add-ins to do what I thought used to be simple things.

It appears to me that there has been a resurgence to move away from the barrage of constant abstractions, and to instead embrace the simplicity of the web (see the popularity of REST, Rails, and the buzz around ASP.NET MVC for some examples of this).

So for me, the reason I am excited is that not only can I once again utilize my knowledge about how the web works, but I can use it in new ways that will make my applications even better (e.g. TDD, scaffolding, etc.). At any rate, here's the set of links that I think matter for ASP.NET MVC:

Monday, December 10, 2007 2:40:56 PM (Central Standard Time, UTC-06:00)  #    Comments [0] -
.NET | ASP.NET
# Friday, December 07, 2007

I wanted to attend CodeMash last year, but waiting until the last minute worked against me. This year I made sure to commit to the event early, so I just signed up and got my hotel reservations sorted out. The sessions look to be pretty deep for a smaller conference, and I'm excited about going there to talk shop.

If you'll be going, drop me a line via comment here, and we'll be sure to sit down and have a beverage or 2. If you're in the Milwaukee/Madison area, and want to chat ALT.NET, it might be a good place to formally plan and launch the Milwaukee meetup.

Hope to see you there!

CodeMash – I&apos;ll be there!

# Monday, November 26, 2007

If you see an error like the following:

MSB6006: "NCover.Console.exe" exited with code 1. in build.proj(93, 3)

be sure to check that you are using the correct version of CoverLib.dll. In older versions of NCover (e.g. 1.5.8), by default, this dll should be registered every time the NCover task is run. I haven't found that to be true, though. I had an older version of NCover installed somewhere else on the build machine, and I kept on having my build fail because version 1.5.8 of NCover.Console.exe was loading version 1.5.5 of CoverLib.dll.

By manually registering the correct version of CoverLib.dll, I got the build working again.

Monday, November 26, 2007 10:21:48 PM (Central Standard Time, UTC-06:00)  #    Comments [0] -
.NET
Navigation
Archive
<May 2012>
SunMonTueWedThuFriSat
293012345
6789101112
13141516171819
20212223242526
272829303112
3456789
About the author/Disclaimer

Disclaimer
The opinions expressed herein are my own personal opinions and do not represent my employer's view in any way.

© Copyright 2012
Dan Miser
Sign In
Statistics
Total Posts: 380
This Year: 8
This Month: 0
This Week: 0
Comments: 670
Themes
Pick a theme:
All Content © 2012, Dan Miser
DasBlog theme 'Business' created by Christoph De Baene (delarou)