Want to learn a different language? Over the course of 25 episodes, our friend Bob Tabor, from www.LearnVisualStudio.net, teaches you the fundamentals of visual C# programming. Tune in to learn C# concepts applicable to video games, mobile environments, and client applications. We walk you through getting the tools, writing code, debugging features, customizations, and much more! Each concept in this C# for beginners course is broken into its own video so you can search for and focus on the information you need.
Instructor | Bob Tabor – Microsoft MVP
Welcome to this series of lessons about the C# programming language. In this episode, Bob Tabor, from LearnVisualStudio.NET, introduces the topic, sets expectations for the series, and provides tips on how to get the most out of it. Bob also tells you where you can download the software you need to get started and offers some encouragement as you begin your journey.
If you're not sure which version of Visual Studio to install or how to go about it, this video guides you in the right direction. You may skip this lesson if you already have Visual Studio 2013 Professional or later installed or if you have Visual Studio Express 2013 for Windows Desktop or later installed.
This lesson teaches you how to create a simple application—first using Windows Notepad and the C# Command Line Compiler, and then by using Visual Studio or Visual C# Express Edition. The video concludes with an explanation of common solutions to the many different problems you might encounter as you first begin writing and compiling code.
Follow an in-depth discussion of each completed action and written line of code. Explore the relationship between the C# code, the C# compiler, and the .NET Framework. The lesson also covers the concept of code blocks at a high level. Finally, the lesson shows you where your project files are stored and the different types of compilation.
See demonstrations of some common Visual Studio IDE features, various windows, debugging features, code window features, and customizations found in Visual C# Express Edition. A more complete discussion of features is found in the Visual C# Express Edition Fundamentals series and the Visual Studio Fundamentals series, both of which are available on Channel 9.
Here, we start adding C# syntax to your vocabulary by talking about fundamental building blocks: data types and variables. We also discuss basic topics, such as naming conventions and data type conversions.
Branching allows us to add logic to our applications. This lesson introduces the ‘if Decision’ statement (in its various forms), along with the conditional operator. We also discuss how to refactor our code to make it more compact and less likely to produce errors, by eliminating duplicate code.
In this lesson, we discuss how to create a properly formed C# statement. We discuss how statements are made up of expressions and how expressions are made up of operators (think: verbs) and operands (think: nouns). Finally, we talk about compilation errors that occur when the syntax rules of C# are ignored.
Iterations allow our applications to loop through a block of code until a condition is satisfied. We cover several different types of iteration statements throughout this series, how to utilize "code snippets" to help remind you of the syntax for this complex statement, and debugging in action.
In this lesson, we talk about arrays, which are multi-part variables—a "bucket" containing other "buckets," if you will. We demonstrate how to declare and utilize arrays, and we demonstrate a couple of powerful built-in methods that give arrays added features.
Now, we begin wading into the topic of methods by creating a helper method to break out code we may need to use in multiple places within our code. We create and call our methods to retrieve a value, create and use input parameters, learn about string formatting, and create overloaded versions of our method.
Learn a new type of iteration statement (while) and how to utilize the StreamReader class to stream data from a file to the Console window. Additionally, we learn how to add new files to our project, how to set properties of our file using the Properties window, and how to add a using statement as a means of resolving a class name referenced in our code to the namespace in which it is defined.
Since oftentimes in our applications we'll want to work with string data, this lesson approaches a number of different string manipulations. We look at built-in String methods to manipulate the content inside of a literal string and at the StringBuilder class for concatenating many strings together in a memory and resource-friendly manner.
Like strings, dates and times are represented using special types and so deserve some attention. In this lesson, we learn how to work with Date and Time data, how to create new instances of DateTime, how to add time, and how to format the data for display. We also discuss the TimeSpan class.
Classes are integral to the .NET Framework, particularly the .NET Framework Class Library. Learn how classes are defined and new instances are created, how to define Properties, and how to both set values and get values for a given instance of the class.
This lesson digs into more details about classes—what exactly happens when you create a new instance of a class? What is a reference to an instance of a class? How does passing the reference to a method affect a class? We also review overloaded methods, static versus instance methods, and constructors.
This lesson continues to teach concepts about classes (specifically, in this case, inheritance) by showing you how to utilize inheritance in your own custom classes. Learn about overriding virtual functionality, abstract base classes, and sealed classes.
In this lesson, we explain how Namespaces allow us to disambiguate classes that may share the same name. And we explain how the .NET Framework Class Library is so large that including all its classes in every application you write is a waste of system resources. Certain project templates include references to the typical assemblies required by a given type of application, and we demonstrate this by referencing a custom assembly of Bob's own design.
Explore the scope of variables within code blocks and how accessibility modifiers, such as Public, Private, and Protected, are used by the .NET Framework Class Library to expose or hide implementation of their given services to consumers of that given class. This is sometimes referred to as "encapsulation."
Here, we demonstrate the use of Enumerations because, in the .NET Framework Class Library, properties can often be set only to a predetermined subset of possible values. To illustrate this point, we create our own custom enumeration and then utilize it in a simple application that demonstrates a third Decision statement, the switch.
Exceptions occur when an application experiences some unexpected problem at run time. This lesson discusses how to use the try catch finally block to anticipate potential problems and to attempt to shield the end user from those problems as much as possible. We also explore best practices when checking for exceptions.
Collections are a more powerful form of arrays. In this lesson, we demonstrate an "old style" collection (pointing out its limitations), along with several of the newer, strongly typed generic collections (List<T> and Dictionary<T1, T2>) utilizing the generics syntax.
In this lesson, we discuss how Structured Query Language provides a means of working with sets of data. Similarly, the LINQ syntax provides a simple way of working with groups of data in generic collections. We demonstrate projecting data onto existing types and new anonymous types.
Learn how events are utilized in the .NET Framework Class Library specific to WPF and ASP.NET Web Forms applications. In these examples, we see how C# is generated by the IDE to "wire up" a user action or application event to the code that handles that event.
In this final video, Bob talks about approaches to solving common issues that arise for new software developers, where to turn for help, how to search for answers to technical questions, and how to become part of the .NET community. He also provides a long-term path that you can follow to learn more about developing Windows and web applications.
Free Microsoft Training Delivered by Experts