Programming Tips - How can I programatically change the title of a Command Line window?

Date: 2010may19 OS: Windows Platform: Windows Language: C/C++ Q. How can I programatically change the title of a Command Line window? A. There is a built-in command:
title My Title
Or you can invoke it this way:
cmd /c title My Title
Or in C/C++ like this:
system("cmd /c title My Title");
But this is nicer (from a C/C++) program:
SetConsoleTitle("My Title");