June 09, 2008 | Comments: (0)
Over on the Advice Line blog, a reader who signs himself "Need help from Bill Gates" asked Bob Lewis about an upgrade project from a Windows application using MDI to the .Net Framework. The architects he talked to pooh-poohed Windows Forms as "old school" and pushed Web applications, Windows Presentation Framework, and Silverlight. Bob said "it depends" and suggested another conversation with the architects about fashion vs. style.
Here's my answer:
Dear Need-Bill ...
You need to talk to different architects, ones who will listen to what you want and analyze what you need instead of pushing the latest technology because it's glitzy.
Web applications have an advantage over desktop applications when it comes to installation and accessibility, but they aren't as responsive as desktop applications at this point. Windows Forms (WinForms) is the right technology if you want to build a Windows desktop application with the .Net Framework that will provide maximum productivity to people who use the application heavily, especially if they enter lots of data.
Windows Presentation Framework (WPF) offers additional graphical capabilities for desktop applications, but requires more in the way of hardware than WinForms to run well. I'm not sure your customers need or could benefit from the advanced graphics, and they might not want to upgrade their computers to run it.
Silverlight is a rich Internet application technology. It implements a subset of WPF as a Web browser plug-in.
Beautiful things can be done with Silverlight rich Internet applications, but you'd need Silverlight 2.0 if you wanted to build one that would be useful for line-of-business or data entry: Silverlight 1.0 doesn't even have a native text input control. Silverlight 2.0 has not yet been released: it is still being beta tested, and beta 2 was just released on Friday.
Posted by Martin Heller on June 9, 2008 08:03 AM
May 13, 2008 | Comments: (0)
Visual Studio 2008 SP1: To beta, or not to beta?
As I mentioned in An old Visual Studio problem rears its ugly head back in February, I've been looking forward to SP1 for Visual Studio 2008 and NET Framework 3.5. Why? These are supposed to fix most of the problems I've been having with Visual Studio, and restore most of the functionality that was cut from the initial 2008 release.
SP1 is out, but only as a first beta-test version. As is true with most beta-test products, there are risks to running it, ranging from a high likelihood of encountering new bugs to a low likelihood of trashing your system to the point where your most effective option is to reinstall Windows from scratch on a newly formatted partition, also known by the woodworking analogy of scraping your drive down to the bare bits.
The list of improvements in this version is impressive. Both Scott Guthrie and Brad Abrams have discussed these in their blogs. Brad does a great job of covering new features; Scott does too, in a slightly different way, and also highlights the known incompatibilities.
Here are the "gotchas", copied from Scott's blog:
1) If you are running Windows Vista you should make sure you have Vista SP1 installed before trying to install .NET 3.5 SP1 Beta. There are some setup issues with .NET 3.5 SP1 when running on the Vista RTM release. These issues will be fixed for the final .NET 3.5 SP1 release - until then please make sure to have Vista SP1 installed before trying to install .NET 3.5 SP1 beta.
2) If you have installed the VS 2008 Tools for Silverlight 2 Beta1 package on your machine, you must uninstall it - as well as uninstall the KB949325 update for VS 2008 - before installing VS 2008 SP1 Beta (otherwise you will get a setup failure). You can find more details on the exact steps to follow here (note: you must uninstall two separate things). It is fine to have the Silverlight 2 runtime on your machine with .NET 3.5 SP1 - the component that needs to be uninstalled is the VS 2008 Tools for Silverlight 2 package. We will release an updated VS 2008 Tools for Silverlight package in a few weeks that works with the VS 2008 SP1 beta.
3) There is a change in behavior in the .NET 3.5 SP1 beta that causes a problem with the shipping versions of Expression Blend. This behavior change is being reverted for the final .NET 3.5 SP1 release, at which time all versions of Blend will have no problems running. Until then, you need to download this recently updated version of Blend 2.5 to work around this issue.
I wouldn't install this version on my primary development system, but I might install it on a secondary development system after doing a full back-up.
To beta, or not to beta? Maybe both.
Posted by Martin Heller on May 13, 2008 11:37 AM
October 18, 2007 | Comments: (0)
Creating and Using a Data Access Layer with Visual Studio 2005
Every time I do this I have to figure it out again. (Sometimes I empathize with HAL, when he is being dismantled at the end of 2001: "My mind is going, Dave. I can feel it.") I'm blogging this as much for myself as for anyone else it might help.
Here is the magic spell you need:
- Create a Class Library project in your solution in the supported language of your choice. I like C#, but Visual Basic .NET also works. I usually end the project name with DAL so that I can remember what it is.
- Delete the Class1.cs (or .vb) source file that is created automatically.
- Right-click on the project and add a new DataSet item. The design surface for an XSD file will open.
- Open a data connection to the database you're wrapping.
- Select each table you want to use and drag it to the design surface.
- Build the data access layer project.
- Add a reference to the data access layer project to your UI project. It doesn't really matter whether the UI project is a Windows Forms application, an ASP.NET application, a console application, or a Windows Presentation Foundation application.
- Add a using (or Imports) statement for the table adapters of the data access layer to your UI project. IntelliSense will help out if you added the reference properly.
Now you can instantiate the table adapters in your code and call the appropriate pre-generated methods for whatever CRUD operations you need. If you need other operations, you can go back to the DAL and add them: right click at the bottom of the table in the DataSet diagram and add a query.
Posted by Martin Heller on October 18, 2007 08:06 AM
March 12, 2007 | Comments: (0)
Free Lessons for Beginning .NET Programmers
When the free Express editions of Visual Studio were first announced, the Microsoft .NET Development Series got quite a few proposals for books aimed at amateur and novice programmers. As Series Editor, I always had to ask how much money someone would pay to learn how to use a free development environment. My gut feeling was "nothing:" the free IDEs would need free training, meaning that the business opportunity for Express-specific books was practically non-existent.
It has been a long time coming, but Microsoft now has a site for this, the Beginner Developer Learning Center. At first examination, I'm quite impressed.
The site is divided into two major tracks, one for Web development and one for Windows development. Within each track, there are lessons in each of three tiers. Tier 1 lessons assume no prior software development knowledge; tier 1 lessons assume that you understand the foundations of .NET development. Tier 3 lessons "expand your knowledge of Windows and Web development with more advanced concepts such as data access and debugging." (Pay no attention to the man behind the curtain rolling his eyes at this last statement.)
In addition, the Learning Center has a Kid's Corner with cartoony introductions to C#, VB, and Web development. I found these corny myself, but I haven't yet tried them out on my middle-school-aged kids.
For reference, the site has video "how-to" guides to Windows Forms and Web Forms controls in C# and Visual Basic, and a video "how-do-I" series about ASP.NET. Finally, it has a "Tips and Tricks" series of assorted video and PDF guides, for things like creating templates and deploying applications with ClickOnce.
These short video guides are very much in the same spirit as the short videos we produce here on InfoWorld.com. As with our videos, the production values might not be anything to write home about, but the information presented is right on the money.
Posted by Martin Heller on March 12, 2007 06:00 AM
TOP STORIES
ADDITIONAL RESOURCES

- Remote Access: Maintain Security and Decrease the Burden on IT
- Beyond AntiVirus: Symantec Endpoint Protection
- What Every Enterprise Needs to Know About VDI

- Monitor the core and troubleshoot the access layer
- Help Simplify Virtualization
- Solution for Open Virtualization Provides Server Consolidation


