Can't wait for Whidbey, but even today, ASP.NET rocks!

I'm currently working on a new article for the MSDN ASP.NET Developer Center on building a registration and login server control for ASP.NET v1.1. Sure, Whidbey will have controls to do this baked right into the framework, but for now, the control I'm showing how to build will provide some of the same functionality, and you can use it right away.

Which brings up an important point. After the great Whidbey stuff that was shown off at PDC, it's kind of easy to get discouraged by the fact that we have to wait for the new controls, enhanced productivity, and other great features of ASP.NET in Whidbey. But the fact is that even today, development with ASP.NET is fast, easy, and productive.

For example, as a bonus for the source code download for the article I'm writing, I decided to add another control that is a lightweight version of the LoginStatus control that will ship with ASP.NET Whidbey. To implement a control that:

  • Detects whether the user is logged in
  • Renders a hyperlink with the text "Log In" or "Log Out"
  • Responds appropriately to the user clicking the link by either redirecting to the configured (via a property) login page or signing the user out
  • Implements a designer class to render a simple link at design time
took all of 40 lines of code (including class statements, etc.) and less than an hour to build and test. Just imagine trying to do the same thing in classic ASP...and still make it reusable across multiple apps.

So while it's easy to get frustrated about the hype surrounding new platforms and versions, and even easier to be impatient for the new features to be available, it sometimes helps to remind ourselves just how good the tools and technologies we use today have gotten.

2 Comments

  • I think that somwhere along the line, the real power of the component concept got missed by a lot of people.



    The power of the design-time environment of Visual Studio is pretty impressive, but the documentation is almost non-existant, it mostly list the names of props and methods.

    The samples that return "This is the control" from GetDesignTimeHtml are overly simplistic.



    I've been pounding away at custom designers and type converters, and the more I do , the better I understand and the easier it seems to be.

    My latest control is a resource based literal, that shows the localized text at design and run time.



    It took lots of digging , but in the end it's fairly simple.

    Is there a list somewhere of the services available at design time in VS.Net or a way to enumerate the services?



  • Reflection of course, and a little brute force.



    I loaded every assembly from the GAC and tried every type to see if I would get something when I called GetService(type).

Comments have been disabled for this content.