JethroStoltzfus :
I was wondering can you program in just c# or does it have to be c# wpf, C# consol, etc.
Hi,
C# is a programming language that was developed in coordination with the Common Intermediary Language (CIL) and Microsoft .NET Framework.
The .NET Framework is a combination of a virtual machine (runtime) which converts CIL bytecode into x86/ARM machine code on the fly and a set of libraries (the class library) which provide functionality. Since the C in CIL stands for "Common", any language that compiles to CIL can utilize the CIL libraries and run on the .NET runtime. Although C# is perhaps the most common language, Visual Basic .NET, managed C++, and Java are all capable of targeting CIL.
At the center of the class library is the standard library. The CIL standard library is similar to the standard library for other languages such as C, C++, and Java. However, the CIL standard library is absolutely massive, much wider in scope than anything before it. The standard library provides a variety of common functionality such as dealing with date/time, files, text encoding, networking, reflection, lists/queues/collections, etc... The standard library is abstract enough to be portable, nothing about it relies on any "Windows Specific" behaviour. In fact, the standard library is standardized, other CIL runtimes such as Mono provide their own runtime for other operating systems such as OSX and Linux.
In addition to the standard library, the .NET framework ships with a variety of auxiliary libraries that are linked to Windows specific behaviour. This includes Windows Presentation Foundation, Windows Forms, Office tools, DirectX, Active Server Pages, etc... These libraries are not standardized, and in many cases are encumbered by patents. While Microsoft has made effects to standardize and unencumber much of this, that process is not yet complete.
If you were to write a program in C# that relied upon only CIL and the CIL standard library that program would run on any CIL virtual machine on any operating system for which an appropriate implementation exists. However, reliance on CIL libraries for which no non-.NET implementation exists would necessarily limit the program to running on Windows for the time being.