MSDN Documentation

Microsoft Developer Network - Your Gateway to .NET Technologies

C# Sample Projects

Explore a curated collection of C# sample projects demonstrating various aspects of the .NET framework and C# language. These samples are designed to help you learn, understand, and implement solutions efficiently.

Basic Concepts

Variables and Types Sample

Variables and Data Types

Understand fundamental C# data types and how to declare and use variables effectively.

View Sample
Control Flow Sample

Control Flow Statements

Learn about if-else, switch, loops (for, while, foreach) for directing program execution.

View Sample
Methods Sample

Methods and Functions

Discover how to define and call methods to create reusable code blocks.

View Sample

Advanced Features

OOP Concepts Sample

Object-Oriented Programming (OOP)

Explore classes, objects, inheritance, polymorphism, and encapsulation in C#.

View Sample
LINQ Sample

LINQ (Language Integrated Query)

Master querying collections and data sources directly within C#.

View Sample
Async/Await Sample

Asynchronous Programming

Learn to write efficient, non-blocking code using async and await patterns.

View Sample

Web Development with ASP.NET Core

Web API Sample

RESTful Web APIs

Build powerful web services and APIs using ASP.NET Core.

View Sample
MVC Sample

ASP.NET Core MVC

Develop dynamic, data-driven web applications with the Model-View-Controller pattern.

View Sample

Desktop Applications

WPF Sample

WPF Applications

Create rich, interactive desktop applications with Windows Presentation Foundation.

View Sample
WinForms Sample

Windows Forms

Build traditional Windows desktop applications with ease.

View Sample