Getting started with Windows programming

Carson Dyle

Diamond Member
Jul 2, 2012
8,173
524
126
I'm a professional programmer, going back 20 years or so. I have experience with C, some C++, and a handful of scripting languages like Perl. But I've never developed GUI apps for Windows. Mostly what I've done for the past 13 years is web programming. And, frankly, I'm sick of it.

What tools are considered standard for developing commercial Windows desktop applications? I've seen and used plenty of apps on Windows with oddball user interfaces, strange widgets, very unconventional ways of doing things, and I'm not interested in going there, even to start out. And then... what is the least expensive route to acquiring the tools? I would guess some kind of Microsoft Technet subscription or other.
 

Merad

Platinum Member
May 31, 2010
2,586
19
81
The Visual Studio Express versions are free downloads. C# is probably the easiest way to go about GUIs at present. Should be easy to pick up if you aren't too rusty on the C/C++.
 

Markbnj

Elite Member <br>Moderator Emeritus
Moderator
Sep 16, 2005
15,682
14
81
www.markbetz.net
What Merad said. Once you have the environment look into Windows Forms (the older technology), or Windows Presentation Foundation (the newer whiz-bang technology). You can also look into Silverlight, which can create applications that run in either a browser plugin or on the desktop.
 

EagleKeeper

Discussion Club Moderator<br>Elite Member
Staff member
Oct 30, 2000
42,589
5
0
See, Mark is such a youngster that he considers Windows Forms old.

Completely forgetting about MFC and the underlying Win32 API for graphics. (1990's)
 

Markbnj

Elite Member <br>Moderator Emeritus
Moderator
Sep 16, 2005
15,682
14
81
www.markbetz.net
See, Mark is such a youngster that he considers Windows Forms old.

Completely forgetting about MFC and the underlying Win32 API for graphics. (1990's)

Hah. Yeah, MFC I have actually removed from my memory via intensive therapy. The Win32 API is like the sewer system in NYC... it's there, but you don't think about it.
 

Carson Dyle

Diamond Member
Jul 2, 2012
8,173
524
126
Most/all of the above is suggesting using .NET, correct? I admit that I haven't been paying attention much to Windows development over the years. Is .NET more of a 'quick and dirty' development environment, or are real life commercial software products utilizing it?
 

DaveSimmons

Elite Member
Aug 12, 2001
40,730
670
126
Most/all of the above is suggesting using .NET, correct? I admit that I haven't been paying attention much to Windows development over the years. Is .NET more of a 'quick and dirty' development environment, or are real life commercial software products utilizing it?

Some high-performance programs like games still use "unmanaged" C/C++ without the .NET runtime, but a lot of commercial programing and most corporate programming is done with .NET these days.

.NET is now more than a decade old, so MS has had the 3 revisions needed to get it right (Actually C# is version 5 now, and .NET is v. 4.5)
 

Sureshot324

Diamond Member
Feb 4, 2003
3,370
0
71
Most/all of the above is suggesting using .NET, correct? I admit that I haven't been paying attention much to Windows development over the years. Is .NET more of a 'quick and dirty' development environment, or are real life commercial software products utilizing it?

Do you want to get a job developing commercial windows GUI apps, are are you looking to develop your own and possibly selling them?

High end commercial software that is also sold to consumers like photoshop, 3D modeling/animation, and audio production apps are not going to be using .NET anytime soon because customers won't be happy paying thousands for software that takes the easy but less efficient way and uses .NET, even if it's just for the UI. I think most of that software still uses straight Win32 API, or a library that sits on top of it like Qt or (shudder) MFC.

If you want a job developing Windows GUI apps, the vast majority are going to be C# .NET corporate apps, and this is not going to be much different from developing corporate web apps.

If I were going to get into developing desktop apps myself, I would use a library like Qt or GTK. This is more efficient than .NET and makes it easy to port your app to Linux/MacOS.
 
Last edited:

Markbnj

Elite Member <br>Moderator Emeritus
Moderator
Sep 16, 2005
15,682
14
81
www.markbetz.net
High end commercial software that is also sold to consumers like photoshop, 3D modeling/animation, and audio production apps are not going to be using .NET anytime soon because customers won't be happy paying thousands for software that takes the easy but less efficient way and uses .NET, even if it's just for the UI. I think most of that software still uses straight Win32 API, or a library that sits on top of it like Qt or (shudder) MFC.

I agree with your conclusion, but not with your description of the motivation. For the most part end users neither know, nor care, what framework a program is written on. Most of these kinds of apps have been around a long time and are built on huge legacy code bases. If someone were writing a new CAD package in Windows I wouldn't be surprised if they built the front-end on .NET. There would not be any "efficiency" downside to doing so, and it would be a lot faster to build.

The idea of using a cross-platform lib like Qt is a bigger decision. If you want to, or might want to, sell on those other platforms then it might make sense, but everyone who has done that knows that what you end up with is not the best of both worlds, and the result can be disappointing to users on all the platforms.
 

Sureshot324

Diamond Member
Feb 4, 2003
3,370
0
71
I agree with your conclusion, but not with your description of the motivation. For the most part end users neither know, nor care, what framework a program is written on. Most of these kinds of apps have been around a long time and are built on huge legacy code bases. If someone were writing a new CAD package in Windows I wouldn't be surprised if they built the front-end on .NET. There would not be any "efficiency" downside to doing so, and it would be a lot faster to build.

The idea of using a cross-platform lib like Qt is a bigger decision. If you want to, or might want to, sell on those other platforms then it might make sense, but everyone who has done that knows that what you end up with is not the best of both worlds, and the result can be disappointing to users on all the platforms.

The .NET runtime is a virtual machine with a JIT (just in time compiler) similar to Java. .Net apps are compiled to byte code and when the application runs certain 'hotspots are compiled to native machine code and the rest of the byte code is translated as it runs. Like Java, this means higher startup time to compile the hotspots, and slower execution of the non hotspots.

There are are new windows apps still being made that use native GUI code. The windows version of Google chrome uses WTL. WTL is basically Microsoft's successor to MFC and is probably a good choice for the OP.
 

Markbnj

Elite Member <br>Moderator Emeritus
Moderator
Sep 16, 2005
15,682
14
81
www.markbetz.net
The .NET runtime is a virtual machine with a JIT (just in time compiler) similar to Java. .Net apps are compiled to byte code and when the application runs certain 'hotspots are compiled to native machine code and the rest of the byte code is translated as it runs. Like Java, this means higher startup time to compile the hotspots, and slower execution of the non hotspots.

The vast majority of GUI code sits in a message loop doing essentially nothing, waiting on the slowest component in the system, i.e. the user. The only aspect of performance that matters is the perceived "snappiness" of windows and controls, and .NET has no issues there, unless the code is poorly written.

Having written GUI applications in every flavor of the windows API from Win16 onward I would choose .NET in a heartbeat if I had to do a new one, and in fact the last one I did was a digital media manager/player in .NET 3.5/WPF. That app was written for a major media company, and has something like 3m users at this point. As far as I'm concerned the only downside to it was the necessity of the additional download/install of the framework, which has largely receded as an issue since vista.
 

Obsoleet

Platinum Member
Oct 2, 2007
2,181
1
0
"Getting started with Windows programming"

Simply put: don't.

Unless you're in the corporate world, already writing .Net apps, I don't know why you'd use .Net in this day and age.

The posterboy of .Net (C#) is taking steep dives in usage and popularity http://www.tiobe.com/index.php/content/paperinfo/tpci/index.html

MS is backing away from .Net http://arstechnica.com/information-...tware-developers-the-longhorn-dream-reborn/2/

I think .Net's partial abandon is also evidenced with the absence of a new XNA release (the latest is 2 years old discounting the 'refresh').

All signs outside of the corporate world are pointing more towards higher level languages to increase programmer productivity (Python and Ruby) or more low level (C / C++). Personally I'd pick something high level if you want a crossplatform GUI app. If you want to prepare yourself for a career in corporate enterprise, by all means... hop into a $500 copy of Visual Studio.
Not saying you can't do anything in .Net... just don't know why you'd pay for Visual Studio and wait for them to drop more technology..

I've seen things dropped from Silverlight, VB6, Sourcesafe, whatever you build your company on and become entrenched in, they'll drop it when no longer in their interests.
Rely on the open source world. If nothing else you can maintain your own product after MS decides you don't need it any longer by hiring a C/C++/Python programmer (or do it yourself).

All that said, to dissuade you from a platform being backed away from (.Net) from a sole-source providers (MS).. C# is a great language itself. Has nothing to do with the rest of my argument though.
Since GUI apps are becoming more and more legacy apps in the age of webapps, Python should be fine. If you need more performance (Photoshop-level, something hardcore), forget .Net/C#, go straight to C++ and be done with it.
 

Carson Dyle

Diamond Member
Jul 2, 2012
8,173
524
126
How many corporations are developing Windows based apps these days? I would think the vast majority of in-house apps today are browser based. Along with online browser apps, that's essentially what I've been doing for the past 15 years, and it's gotten old.

I'm a little more interested in developing shrink-wrapped applications. Perhaps some shareware, perhaps get involved with some open source projects.
 

Leros

Lifer
Jul 11, 2004
21,867
7
81
How many corporations are developing Windows based apps these days? I would think the vast majority of in-house apps today are browser based. Along with online browser apps, that's essentially what I've been doing for the past 15 years, and it's gotten old.

I'm a little more interested in developing shrink-wrapped applications. Perhaps some shareware, perhaps get involved with some open source projects.

There are ton's of companies that write purely Windows based applications. The corporate/enterprise world is still very Window's focused. But yes... things are moving towards are browser-based apps.
 

Markbnj

Elite Member <br>Moderator Emeritus
Moderator
Sep 16, 2005
15,682
14
81
www.markbetz.net
Why do you dislike XAML? Laying out UI with XML makes much more sense to me than doing it in code. I wish there was something like XAML for Java.

Agreed, big time. It's a nice analog with the way ASP.NET decomposes web pages. It's also a hell of a lot faster to develop slick custom interfaces in XAML.
 

Markbnj

Elite Member <br>Moderator Emeritus
Moderator
Sep 16, 2005
15,682
14
81
www.markbetz.net
The posterboy of .Net (C#) is taking steep dives in usage and popularity

Interesting that the top five languages on that chart are all C or derivatives of C.

If C# is dropping in popularity (I don't know how they come up with those numbers) then it is likely due to the shift toward mobile platforms and Microsoft's lack of a viable solution in that realm.
 

Obsoleet

Platinum Member
Oct 2, 2007
2,181
1
0
How many corporations are developing Windows based apps these days? I would think the vast majority of in-house apps today are browser based. Along with online browser apps, that's essentially what I've been doing for the past 15 years, and it's gotten old.

I'm a little more interested in developing shrink-wrapped applications. Perhaps some shareware, perhaps get involved with some open source projects.

A lot as Leros said. I've done both in different roles, webapp and local. It really depends on the need. I'd probably make something local if it wasn't used by a ton of people or needed to be reached by a lot of employees.
We have more advanced local apps that do some stuff that webapps aren't suitable for (software upgrades for example). Basic text input, stuff that would've been done with paper files years ago are webapps, at least the ones I've created.

I wouldn't start on .Net stuff today though, local or webapps. Unless its for financial incentive for a job, there's no shortage of MS stack jobs and there's nothing wrong with them or that fact. There's also no shortage of PHP jobs and nothing wrong with that either.
I use Mono (not much, but it's free). Why not install MonoDevelop and get your feet wet. Honestly, I prefer it for a lighter weight install than VS. Seems everytime I install VS there's no getting rid of it and it's heavy as can be. It's just invasive, its screwed up Windows installs of mine before. While its the best IDE out there, I just don't like it unless its on a company provided machine.

Since GUI apps are becoming more and more legacy apps in the age of webapps, Python should be fine. If you need more performance (Photoshop-level, something hardcore), forget .Net/C#, go straight to C++ and be done with it.

I'd like to expand on this comment. Instead of getting into C++ for a GUI app, I'd prefer to use Python + Cython, you'll still get the performance increase. Not sure on the limitations to Cython vs working on C++ but it's where I'd look. That's just me, it's always easier to use what you already know.

Interesting that the top five languages on that chart are all C or derivatives of C.

If C# is dropping in popularity (I don't know how they come up with those numbers) then it is likely due to the shift toward mobile platforms and Microsoft's lack of a viable solution in that realm.

I'd guess it's because the mobile realm has no dominant player other than Objective-C, and since they won't use that, they adopted HTML5+JS. Brings in a lot more guys than just the C# crowd. No one's corporate backed language besides Obj-C is really taking off. In fact, unless the OP wants a corporate-drone job hacking away on C# GUI apps all day, ObjectiveC would probably be the better investment of time and effort.

Getting into ObjC, C# on Mono or Python costs nothing and 1st class apps are written with all 3. Paying to develop seems like a huge favor to company X both upfront, then with the dependence / lock-in later on, not to mention the validation you give their pay-to-develop platform.
 

douglasb

Diamond Member
Apr 11, 2005
3,157
0
76
Interesting that the top five languages on that chart are all C or derivatives of C.

If C# is dropping in popularity (I don't know how they come up with those numbers) then it is likely due to the shift toward mobile platforms and Microsoft's lack of a viable solution in that realm.

I think that some of you have a misunderstanding of what these statistics are. These are the most searched-for languages across several search engines. It is not necessarily a list of most-used languages. For example, C is at the top, followed by Java. Guess which 2 languages are used most by universities for teaching students Computer Science. Java and C. It stands to reason, then, that there are lots of Java and C "rookies" out there googling up a storm so they can complete their assignments. It doesn't mean that C is the most-used language in the real world, because clearly it is not.

This statistic is basically meaningless in terms of real-world usage.
 
Last edited:

Nothinman

Elite Member
Sep 14, 2001
30,672
0
0
Good point. You need at least a Macbook and a device, so a couple of grand.

You can get into Objective-C with GCC for free and whatever OS and hardware you want. You only need Apple equipment if you want to use it to make iOS apps.
 
sale-70-410-exam    | Exam-200-125-pdf    | we-sale-70-410-exam    | hot-sale-70-410-exam    | Latest-exam-700-603-Dumps    | Dumps-98-363-exams-date    | Certs-200-125-date    | Dumps-300-075-exams-date    | hot-sale-book-C8010-726-book    | Hot-Sale-200-310-Exam    | Exam-Description-200-310-dumps?    | hot-sale-book-200-125-book    | Latest-Updated-300-209-Exam    | Dumps-210-260-exams-date    | Download-200-125-Exam-PDF    | Exam-Description-300-101-dumps    | Certs-300-101-date    | Hot-Sale-300-075-Exam    | Latest-exam-200-125-Dumps    | Exam-Description-200-125-dumps    | Latest-Updated-300-075-Exam    | hot-sale-book-210-260-book    | Dumps-200-901-exams-date    | Certs-200-901-date    | Latest-exam-1Z0-062-Dumps    | Hot-Sale-1Z0-062-Exam    | Certs-CSSLP-date    | 100%-Pass-70-383-Exams    | Latest-JN0-360-real-exam-questions    | 100%-Pass-4A0-100-Real-Exam-Questions    | Dumps-300-135-exams-date    | Passed-200-105-Tech-Exams    | Latest-Updated-200-310-Exam    | Download-300-070-Exam-PDF    | Hot-Sale-JN0-360-Exam    | 100%-Pass-JN0-360-Exams    | 100%-Pass-JN0-360-Real-Exam-Questions    | Dumps-JN0-360-exams-date    | Exam-Description-1Z0-876-dumps    | Latest-exam-1Z0-876-Dumps    | Dumps-HPE0-Y53-exams-date    | 2017-Latest-HPE0-Y53-Exam    | 100%-Pass-HPE0-Y53-Real-Exam-Questions    | Pass-4A0-100-Exam    | Latest-4A0-100-Questions    | Dumps-98-365-exams-date    | 2017-Latest-98-365-Exam    | 100%-Pass-VCS-254-Exams    | 2017-Latest-VCS-273-Exam    | Dumps-200-355-exams-date    | 2017-Latest-300-320-Exam    | Pass-300-101-Exam    | 100%-Pass-300-115-Exams    |
http://www.portvapes.co.uk/    | http://www.portvapes.co.uk/    |