The API Maze

Tags: .NET

A reminder to those lost:

The SystemInformation class, containing many useful tidbits of information like the running computer name, number of monitors and whether we're on a network, resides in System.Windows.Forms of all places.

Sure, most of the information there is GDI and Forms related, but why do I need to include and reference this in a console application if all I want is the name of the computer? A more generic SystemInformation should be sitting directly under the System namespace.

VB 2005 has the My namespace for easy access to such information - but this is basic enough to be CLR-wide.

2 Comments

Comments have been disabled for this content.