Returning to Windows programming - Is .NET the way to go?

I played with Visual Studio as a kid and made a few programs, then stopped for a decade. I want to get back into it as a hobbyist.

In the intervening time, Microsoft released the .NET framework. As far as I can tell, it’s a fancy collection of APIs and a runtime environment that can be used with a variety of languages and across a variety of devices.

That’s all fine and good, but I only want to write very simple apps for desktop Windows, and the .NET end-user runtime seems to be 50 MB+, whereas the apps I’m envisioning would be hard pressed to exceed a few megabytes.

Is there a better choice? Back when I was a kid, it seemed like you could compile simple .exes that worked with just the basic Windows APIs, including a few .DLLs only if absolutely needed. Is this still possible, or is .NET just the standard way of dong things nowadays – and if so, is it reasonable to assume most people already have the runtime?

Doesn’t the .NET runtime ship as part of all the modern versions of Windows?

Yes, in my opinion is superior to the previous vb6. I dont think that you will run into distribution problems.

A lot of folks still use XP, and even Vista/7 ship with older versions of the runtime. There is no write-once-run-on-any-Windows version of the .NET runtime.

The .NET frameworks are installed 1 per version on a computer. Meaning, you can write 25 .NET framework 4.5 apps and your end user only needs one copy of the framework installed.

If you are looking to get into .NET programming, I would suggest that you consider upgrading from VB into C#. You can do many of the same things in VB.NET as you can in C#, but there are more examples in C# since it is the .NET industry standard.

I have done both VB.NET development and C# and never having to type Dim again is well worth having to use semi-colons to end statements.

If you are building a Windows Form app and use the Click-Once deployment strategy, you can set bootstrapping options, including the installation of the required .NET Framework if it doesn’t exist on target computers. Meaning your customers/users don’t need to know how to download the framework, just that the very first time they run the app it will take longer to start.

Good luck and welcome back to programming.

That sounds interesting.

Does that work with Firefox and Chrome now, or does it still need another plugin like it did back when Click-Once first came out?

And thanks! It’s daunting, but it also seems a lot more mainstream now and there are a billion forums with examples, something we didn’t have quite as many of back in the day.

Definitely learn to program .NET. It’s very programmer-friendly.

Couldn’t tell you, my experience with Click-Once is within my IE only enterprise…
There are a billion forums and websites, however two sites get the majority of my attention; for tutorials, examples, etc. and as a great resource for help. I haven’t actually posted a question at SO but have found dozens of solutions there.

ClickOnce might or might not work on Firefox. I seem to remember Microsoft being criticized for being a bit sneaky when there was a Windows update that sort of secretly installed a Firefox add-on that made ClickOnce work with Firefox. I don’t know the state of that now and what happens if you install FF on a new system. It probably doesn’t work with Chrome.

We use ClickOnce where I work and I tell people to use I.E. to install with. After that it doesn’t depend on I.E. because it installs a desktop icon that will automatically update the app when it’s started if the released version on the server has changed.

If you’re getting back into Windows programming, be aware that “WinForms”, i.e., traditional GDI based Windows desktop applications is pretty much a legacy UI technology. I haven’t really kept up with it but there’s been some confusion as to what UI technology to use. Silverlight and WPF (based on XAML) was the latest big thing for a while but now that “competes” with HTML5 and Javascript. I think the new Windows 8 stuff is quite similar to Silverlight.

.NET is certainly still going strong. C# is a great language. Despite the semi official line that C# and VB.NET are equals, C# is clearly looked upon as the most professional language. I don’t hear much about VB.NET these days.

There is a free version of Visual Studio available from the Microsoft Website.

Visual Studio 2010 Express

Thanks for the advice, all.

I picked up VS Express and I have access to VS Professional through DreamSpark, so the software’s good to go. Visual Studio is even better than I remembered it… say what you will about Microsoft, but I really love this IDE.

I’ve done VB, C++, PHP and Perl before, but C# is still new to me. And I forgot everything I learned about OOP – not that it was ever clearly explained to me in the first place.

Any good recommendations for a book or resource for learning C#.NET as a returning programmer?

There are some free resources on C# and .NET on MSDN; I did a bit of searching on their site and found video tutorials and some guides.

IMO, although it is a slightly bigger learning curve, you might want to go with WPF. I have heard rumors that winforms is going away. (Although, to be fair, I hear those kinds of rumor all the time and you never really know if MS will phase out something until they do.) Still, once I embraced WPF I really liked it.

WPF is pretty much the way to go when designing modern UI. However, windows 8 is allowing HTML5 in it’s metro apps for GUI implementation, and man I would love it if I could use it for desktop applications. Designing and data binding to an HTML5/CSS3/Javascript front end is a hell of a lot easier and faster than doing the same with WPF.