Tutorial Samples

This section contains sample abstracts for the C# Tutorials. Each abstract contains links that allow you to open the sample in the development environment and copy the sample source files to your hard drive.

SampleDescription
Hello WorldShows a Hello World application.
Command Line ParametersShows simple command-line processing; also shows array indexing.
ArraysShows how to use arrays.
PropertiesShows how properties are declared and used; also demonstrates abstract properties.
LibrariesShows how to use compiler options to create a DLL from multiple source files; also, how to use the library in other programs.
VersioningDemonstrates versioning in C# through the use of the override and new keywords.
Collection ClassesShows how to make collection classes that can be used with the foreach statement.
StructsShows how to use structs in C#.
IndexersShows how to use array notation to access an object.
Indexed PropertiesShows how to implement a class that uses indexed properties. Indexed properties allow you to use a class that represents an array-like collection of several different kinds of things.
User-Defined ConversionsShows how to define conversions to and from user-defined types.
Operator OverloadingShows how user-defined classes can overload operators.
DelegatesShows how delegates are declared, mapped, and combined.
EventsShows how to use events in C#.
Explicit Interface ImplementationDemonstrates how to explicitly implement interface members.
Conditional MethodsDemonstrates conditional methods, which provide a powerful mechanism by which calls to methods can be included or omitted depending on whether a symbol is defined.
XML DocumentationShows how to document code by using XML.
Platform InvokeShows how to call platform invokes (exported DLL functions) from C#.
COM InterOp Part 1Shows how to use C# to interoperate with COM objects.
COM Interop Part 2Shows how to a use a C# server with a C++ COM client.
AttributesShows how to create custom attribute classes, use them in code, and query them through reflection.
SecurityDiscusses .NET Framework security and shows two ways to modify security permissions in C#: permission classes and permission attributes.
ThreadingDemonstrates various thread activities such as creating and executing a thread, synchronizing threads, interacting between threads, and using a thread pool.
Unsafe CodeShows how to use pointers.
OLE DBDemonstrates how to use a Microsoft Access database from C#. It shows how you can create a dataset and add tables to it from a database.

See Also

Visual C# Samples

Show: