Following Up on Brendan’s Crystal Post

Brendan has an interesting post about Crystal “from an insiders perspective.” 


Crystal Reports is reporting software that’s marketed well to business decision-makers; Crystal is a household name when it comes to reports!  Most developers, however, work to avoid Crystal Reports like the plague.  Crystal is marketed well to people who write the checks, but not to people who write and implement the reports.  I think a “perception of value” scenario is sometimes at work, too, where something that costs a lot must be very valuable — therefore expensive Crystal Reports must be a great reporting tool.  Following that logic: if we charged people a membership fee to read the blogs on CodeBetter.com they’d percieve the content to be more valuable and worthwhile.


Brendan’s post has another little kernel of wisdom in there . . . the guru points out that Crystal wants to stay ahead of Cognos.  If that’s the gauge Crystal uses, developers don’t do handstands over working with Cognos either.  If it’s between Cognos and Crystal, I’ll gladly take Excel and custom charts any day!


Which brings me to Reporting Services from Microsoft and what a welcome addition it is to the enterprise reporting landscape.  Is it perfect?  No.  Is it better than the alternatives?  Seems to be — although I’m no Reporting Services guru.  They work fine on my machine, though, which is more than I can say for my frustrations with Crystal!

Posted in Uncategorized | 13 Comments

Option Strict On Salvation

Yeah, I should have put this in my earlier post but I didn’t have time.  Maybe I’m crazy, but the whole Option Strict stuff with the TimeTracker starter kit is something I lose sleep over.  The solution is easy: just add a few ToString() and DateTime.Parse() functions where necessary . . . and then you have the whole ubiquitous IIF() function to wrestle with.   There’s dozens of calls to the Option-Strict-On-hating Visual Basic IIF() function scattered all through the starter kit so fight that initial urge to do a search and replace approach.  And no, VB.Net doesn’t have a ? operator either. 


Instead, overload IIF() with the appropriate strongly typed parameters and you’ll be all set.  This is an example:


Public Class IIFHelper
 Public Shared Function IIF( Condition as Boolean, TrueResult as String, FalseResult as String ) as String
  If Condition Then
   return TrueResult
  Else
   return FalseResult
  End If
 End Function
End Class


Repeat as necessary and start using IIFHelper.IIF() instead of just IIF() — I found only a handful of IIFHelper.IIF permutations necessary to get to Option Strict On salvation.


Now I can rest easier. 


 

Posted in Uncategorized | Leave a comment

NHibernate

Anyone having fun with NHibernateThis article from TheSeverSide gives a nice NHibernate overview, but I’m curious about how people are finding the config file management and the tool in general after a bit of real world use.


I’ve used a home grown version that did the same thing; it used a combination of .Net Reflection and CodeSmith.  I wonder if NHibernate is the way to progress in the future . . .

Posted in Uncategorized | 6 Comments

No Option Strict For You

I’m looking at sample apps for some newer .Net web developers to learn from . . . I figured the ASP.Net starter kits would be a good place to start.  One of the things we wanted to include was the importance of Option Strict On vs Option Strict Off and wouldn’t you know it: the TimeTracker Starter Kit app doesn’t use Option Strict On.  I guess I shouldn’t consider a “starter kit” to be the same as a best-practice “reference application” but it would be better for everyone if these sorts of samples stuck to some fundamentals.  Oh well . . . I can use this as an exercise in why they aren’t using Option Strict On and how we can correct it


I won’t even go into what happens when I run FxCop against the starter kit.

Posted in Uncategorized | Leave a comment

Making a Copy of ASP.Net Application — Best Practices?

Somewhere between this article on the .webinfo file and this post about the .csproj file (that incorrectly presumes it’s a Visual SourceSafe problem — I’m no big fan of VSS but it’s not the issue in this case) I successfully made a local copy of a web app we’ve been working on.  Copy the directory . . . make it a virtual directory in IIS, modify the .webinfo file, rename as necessary (webinfo must be same name as the csproj file it seems).


My question: what are the best practices around duplicating a web app on the same box (for running side-by-side as different instances with slightly different interfaces, etc?).  I KNOW that one can deploy the app to different virtual directories, but what I’m after is a form of branching the codebase into a totally new web application on a dev machine with the least amount of effort.  We’ll use VS.Net to make some changes to the UI code for each customer (but reuse the same core assemblies for business logic etc); we’re talking more than just style sheets, here, also.  Too bad “deploying” the app to the same machine (and checking the “include source code” option”) doesn’t configure IIS for you and the other manual work . . .



Writing this post has reminded me of a few projects I’ve been on where all the UI stuff was configured from a database . . . the text of every label, x and y positioning on the screen, presence of dropdown lists and other user input widgets, graphics, etc.  This would solve my particular problem of changing the UI stuff for each customer but introduce a whole host of other architecture issues — think about doing web layout from a set of related SQL Server tables and you’ll get the idea.  


Maybe this would be a handy utility to throw up on something like GotDotNet . . . if GDN didn’t have so many issues.  I guess SourceForge is the main player in the shared project space — but for something as minor as I’m suggesting it might be better off just posted as an EXE somewhere on CodeBetter.  I’ll give it some thought.

Posted in Uncategorized | 1 Comment