Alt.Net Houston Open Spaces 2010

Ben Scheirman is organizing a conference for the Alt.Net community in Houston and I have heard great things about it in the past so I am planning to attend this year.

The conference is organized in the Open Spaces format. For those who have not attended a conference like this before, the idea is simple. None of the sessions (or very few) are officially scheduled in advance. Generally the first day, in this case Friday evening, the group gets together and plans the schedule based on ideas generated from the group and those who volunteer to speak/lead a session. The sessions are generally very good and highly interactive.

The cost is $20 but that includes pre-conference sessions on Friday April 30, a full day of sessions on Saturday, and a few sessions on Sunday with breakfast and coffee included. Check out the conference website to register and hopefully I will see you there.

Heading to TechEd

I’ll be heading to TechEd North America this weekend.  This year it is in Los Angeles. 

I am attending TechEd.  Are you?

It has been quite a while since I’ve been there so I’m really looking forward to it.  Hopefully the flu scare and the economy (and associated budget cuts) won’t cut down attendance too drastically.

Houston ALT.NET Coding Dojo on TDD – May 7, 2009

J.P. Hamilton has organized a Coding Dojo that will cover TDD.  It will be held at the Microsoft offices in Houston at 6pm on May 7th.  Space is limited to 40 participants so sign up early if you want to attend.

Announcing Reference Assistant 1.0

The product I have been working on, Reference Assistant, was released a few weeks ago.  Reference Assistant is an extension for Visual Studio 2005 and 2008 (and soon 2010).  In short, the goal of the product is cut down the time spent debugging runtime errors due to missing dependencies or errors in configuration.


Here are a few highlights of the capabilities in version 1.0:

  • Configuration files for, Windsor, and Unity can be parsed and displayed visually in a tool window.  Missing or incorrectly spelled types are pointed out (project reference paths are searched for required dependencies). 
  • Navigation to object definitions in supported IoC/DI configuration files
  • Any dependencies detected in configuration files can be automatically copied to the project output directory upon successful build.
  • Reference Paths can be setup automatically using rules setup in preferences.
  • Version conflicts between dependencies are displayed visually and in a tool window.
  • Generate a report of all required assemblies for a project’s deployment, including dependencies defined in IoC framework configuration files.
  • Extensions can be written to support custom file formats or configuration types.

For more detail in addition to the product pages, we have written a blog post walking through the functionality available in Reference Assistant for XML configuration.

If you think you or your team could benefit from a tool like this, download a 30-day trial here.

Watch out for those WaitOne() overloads (when you need backwards compatibility)

Recently I was writing some new functionality that ran work on background threads.  The functionality isn’t that important but one of the classes I was using to get the correct behavior was AutoResetEvent.  Specifically the AutoResetEvent.WaitOne() method.

Since I really don’t use this class very often, I relied on intellisense to give the list of method overloads and I selected the WaitOne(Int32) overload which allows the thread to wait a given number of milliseconds unless signaled first.  My compile worked and the functionality ran properly in Visual Studio 2008 SP1.  Since I share the of the same code base when my product is installed in VS2005, I jumped over and the product compiled and ran perfectly there as well.

I forgot all about this until I was doing the final testing in preparation for a new release.  The first few VPC images took the installation and ran fine.  However, when I ran the installation in a VPC image that had a clean installation of VS2005 SP1 and nothing else, the product did not work properly.  I was puzzled until I enabled logging and found that I was getting a MissingMethodException on the WaitOne(Int32) method.

I’ll spare you the details of the agony but I thought about this for a while and decided to try installing the .NET 3.5 SP1 framework in this VM and, low and behold, the problem vanished.

It turns out this method overload was introduced in .NET 3.5 SP1 but because System.Threading resides in mscorlib and there is only a 2.0 version of that assembly, any .NET 2.0 application (which in my case was the VS2005 package) is able to compile against it and run as long as the SP1 version of .NET 3.5 is present on the machine.

The solution was to use the WaitOne(Int32, bool) passing false to the second parameter which gives the same functionality.

I’ll be watching for this type of thing a little closer from now on.

D2Sig in Houston

This past Thursday, I attended the first meeting of the D2Sig in Houston.  The D2 stands for "Developer 2 Designer" and the group will be focused on the XAML technologies of WPF and Silverlight as well as any area where developers and designers might need to work more closely than they have in the past.

Markus Egger from EPS was the presenter and, as always, he gave a great presentation which included a general overview of WPF, Silverlight, and some demo video of a Surface table in action.

I would recommend this new group to designers or developers in the Houston area that are interested in the these new up and coming technologies.

I’m guessing around 30 or so people showed up to the first meeting so I think that is a pretty good start. 

J Sawyer has an official announcement here for the first meeting with a little more detail.  The upcoming meetings will be the first Tuesday of each month at the Microsoft offices in Houston.

ToolStripComboBox Drop Down Sizing

This last night I worked on a bug where I had a ToolStripComboBox in a Visual Studio custom tool window that holds a list of files but would cut off the filenames in the dropdown list if the paths became too long.

Easy enough to fix, or so I thought.  After trying out about all of the property setting combinations I could think of, I never could get the control to automatically size the dropdown list width to accommodate the widest item currently in the list.  This is sort of ridiculous, in my opinion, but I could not find a way to do this without writing some code to do it.

Here is the code that I wrote so hopefully someone will save some time by seeing this and not spend their Friday night on search engines and MSDN attempting to find a way to accomplish the goal:

[sourcecode language=’csharp’]
int i = cboFile.Items.Add(file);
//make sure dropdownlist width is sized correctly
Graphics g = cboFile.ComboBox.CreateGraphics();
SizeF size = g.MeasureString(file, new Font(cboFile.Font.FontFamily.Name, cboFile.Font.Size));
// Set the DropDownWidth if the item has a greater width
int itemWidth = (int)size.Width + 10; //add a little empty space
if (itemWidth > cboFile.DropDownWidth)
cboFile.DropDownWidth = itemWidth;

You can ignore the definition of "i", I was using that later in the code to do some processing specific to my extension.  It is possible that there is an easier way to do this, but I couldn’t find one.

Tags: ,

Updated ASP.NET Dynamic Data Preview Released

Scott Guthrie announced the availability of a new preview of the ASP.NET Dynamic Data functionality.

The idea behind this functionality is that you can generate a fully functional application based upon a LINQ to SQL or LINQ to Entities model.  This reminds me a lot of the Naked Objects Framework from a few years back in the java world.  Naked Objects generated a rich client Swing application but the concept is identical.  It does appear, however, that ASP.NET Dynamic Data allows a little more customization of the UI than I remember from Naked Objects.

I bet if most users of smallish data entry applications knew in advance how much the development of their small application was going to cost them, they would gladly accept an application with limited UI goodness for something quickly available and just works.

I know that I will consider this tool in the future when I need to create small data administration type applications.  Saving time and money on those small applications can make more budget available for the applications that can really impact business capability.

Tags: , ,

Unity Application Block 1.0 has been released

The Unity Application Block version 1.0 has been released and is available on CodePlex here.

A good overview of the configuration of Unity was written by Matthew Podwysocki.

The xml configuration is a little unique compared to other DI containers.  I plan on adding support for the xml configuration to Reference Assistant before the first public beta is out.

Tags: , , ,

Mono 2.0 (.Net 2.0 compatible) is coming soon

According to Redmond Developer News, the beta of Mono 2.0 will be available for download Friday March 14.  Mono is an open source implementation of the .Net CLR and libraries and runs on many platforms, including OSX, Windows, and Linux.

I am a little mystified as to why a developer would target Mono if they need to run on Windows, but then I have always been a little puzzled with certain aspects of the Open Source movement.  If the CLR is free for me to use in terms of costs to me or my customers, and available on pretty much every windows installation out there, then that is free enough for me.

Now targeting other operating systems with Mono is a different matter all together and is where I see Mono as a useful and quite interesting tool.

I will be honest.  I have not following the progress of Mono very closely at all.  When I saw the announcement of the pending beta availability I went to the Mono site and read through their blog.  I was shocked at how much they have working on other operating systems.  I have listened to podcasts with Miguel de Icaza when he talked about the relatively small size of the core Mono dev team so this makes their accomplishments nothing short of astonishing in my view.  Here is a short list of stuff they have working for mac developers:

  • They already have Mono running on the iPhone.
  • ObjC# bindings to provide access to Objective-C APIs from Mono
  • Cocoa# has been developed to provide cocoa bindings.

I would imagine that Silverlight will help out some with Mono adoption since the team is also making that available on Linux via the Moonlight project.

Tags: ,

Next Page »