Ot3

.NET Foundations with C#


Course Outline

This course not only introduces the language and the development environment to the programmer but also gives in-depth understanding of new features in .NET 4 such as "Dynamic lookups, Default and Named parameters, Type Inference, Object Initializers, Lambda Expressions", and so on.
Language fundamentals are presented along with hands-on exercises on how to best implement applications that utilise the core .NET technologies.
.NET Foundations with C# will empower you to build, debug .NET applications utilising your C# skills and knowledge.
This unique course incorporates all theory, examples and practical exercises in C# syntax enabling a wider development and technical audience to use the core features of .NET for 'real-world' applications - more than simply language syntax and tool instruction.


Outcomes

At the end of this course, you will be able to:

  • confidently develop within the C# development environment using the Visual Studio 2010 IDE and compose sound C# syntax. You will also develop a basic understanding of object oriented design concepts within a project.
  • Build, execute and debug C# applications using Visual Studio 2010
  • Produce generated project documentation from a C# project
  • Build C# ADO.NET
  • Gain fundamentals for developing components written in C#

Book Course Now

Please Note: Special prices are available for an In House delivery of this course. Read about the benefits and choices of our 'In House' course delivery option here.

Contact an Object Training Account Manager to enquire about alternative delivery options (such as In House or Customisation).

*All Australian prices are exclusive of GST

*If the course status is FULL or no date is scheduled in your state please contact object training on 1300 360 203

Location Days Dates Cost (ex GST) Course Status
Melbourne 4 Days 20/08/2013 - 23/08/2013 $3000.00 Available Book Now
Sydney 4 Days 09/09/2013 - 12/09/2013 $3000.00 Available Book Now

Topics Covered

An Overview of the .NET Platform
What is Microsoft .NET?
The .NET Runtime Environment
Languages in .NET
.NET Application Execution
Loading an assembly
Managed Execution 
Overview of Programming in .NET
Hello World
Invoking the Compiler
Notes to Recall
The Main Method
The namespace
What to put into namespace
Input/Output
The Read and the ReadLine
Formatting
Generating XML Documentation
XML Tags
Common Type System
Common Type System (CTS)
Value and Reference Types
Type classification
References and Values
Reserved keywords for Simple Types
Working with Simple Types
User-Defined Data Types
Enumeration Type
Enumerator Base Types
Structures
Structures vs Classes
No destructor or custom default constructor
No initialization
Structs are designed to be simple and lightweight
Defining a Structure Type
Create a Structure Type
Implicit Data Type Conversion
Explicit Data Type Conversion
Function Arguments
Pass By Value
Value Types Pass By Reference (C#)
Value Types Output Parameters (C#)
The Variable-length List of Parameters
Invoke a Method with params
Arrays
What is an Array in .NET?
Creating an Array
Array Rank
Declaring Arrays
Instantiating Arrays (C#)
Array Indexing
Accessing Array Elements
Arrays are Objects
Using foreach
Passing Arrays to Methods
Passing an Array class (C#)
Returning an Array from Methods
Classes
A class Introduction
A Simple Class
Access Modifiers
Declaring Reference Variables
Release Reference Variables
Comparing References
Properties in .NET
Accessor Member Functions
Property Accessibility
Indexers (C#)
Using Indexers (C#)
Method Overloading
When to use Method Overloading
Constructors
Default Constructor
Overriding the Default Constructor 
Overloaded Constructor
More on Constructors
Use the Initializer List
The 'is' keyword
The 'as' keyword
The 'using' keyword
The using statement
The 'typeof' keyword
Const fields (Design-time const)
readonly fields (Run-time const)
Object Lifetime
Object Cleanup
Destructor (C# way to Finalize)
The Finalize Method
Why Implement Finalize Method
IDisposable Interface
Implementing Finalization
Finalize Tips
Class scope members
Classes and shared
Inheritance
Expressing Specialization 
Inheritance in UML
Terms: Base and Derived class
Syntax for Inheritance
Accessing Base Class Members
The Base Class Constructors
Calling the Base Class Constructor
Polymorphic methods
Working with polymorphic methods
Override the polymorphic method
Working with overriden methods
Shadowing fields
Shadowing a method
Shadowing polymorphic methods
Stop the further inheritance
Abstract Classes
Inheriting an Abstract class
Implementing Abstract Methods
Interfaces
The Power of Interfaces
Another interface
The UML notation for the example
Implementing many Interfaces (C#)
Interface in use
Explicitly implement interface 
Rules about Explicit Methods
What's New in C#2 Generics
Two main benefit for generics
Boxing needed without generics
Boxing not needed with generics
Life without generics
Dynamic array example
Generic code
Consuming a Generic class
Type Parameters Constraints
Generic Methods
Inheritance
Generic Method overidden C#
Inheritance and overriding C#
Generic Interfaces C#
Generic Delegates
Design Guidance
Nullable Types
The Nullable<T> class
Nullable <T>
C# Language Nullable Types
Nullable Types Assignment
Null Coalescing Operator in C#
Null Coalescing Operator example
Design Guideline
Iterators
Iterators in C#
Non-generic interfaces (.NET 1.x)
Iterators in .NET 1.1 example
Generic Interfaces
Generic IEnumerable in .NET 2
Implement the generic IEnumerable
Let C# 2 write the enumerator for us
The 'yield' keyword
Write a reverse iterator
Flexible iterator
Partial Types
Partial Types
The partial keyword
Anonymous methods
How does .NET 1.x handle events
EventHandler and EventArgs
Handle events with delegates
Anonymous method alternative
Consider a simple class
Object Initializations
Anonymous Methods
Accessors
Property visibility
Indexers visibility
Static Classes
Classes with only static members
Static class
What's new in C#3
Automatically Implemented Properties
Properties and Auto-properties
Change the visibility of the Autoprop
Type Inference
Declaring local objects
Places where to declare var
Anonymous Types
Anonymous Type Definition
Working with Anonymouse types
Lambda Expressions
Lambda Expressions Definition
Lambda Expression Example
C# 1.0 and C# 1.5: Delegates
C# 2.0: Anonymous methods
C# 3.0: Lambda Expressions
Lambda expressions
Lambda operator
Lambda expression example
Multiple parameters
Indicate the types of parameters
Statement Lambdas
Lambda expression practice
Standard delegates
The use of a Func<>
Some more standard delegates
A standard query operator
Standard query operators
Types of standard query operator
LINQ
Language Integrated Query (LINQ)
Standard Query Operators
IEnumerable generic
var example
LINQ example
Lambda expressions inside extension methods
Query Extension Syntax1
Query Expressions
Query Expressions Best Practice
LINQ providers
What's new in C#4
Optional and Named Parameters
Optional parameters
The MSIL in case of optional parameters
Named parameters advantage
Named parameters
Named parameters improves readability
Dynamic Lookup
Prior dynamic keyword
The new keyword 'dynamic'
Dynamic Lookup
Dynamic keyword
Dynamic used as a type
Dynamic keyword used as type conversions
Dynamic keyword use
Some pros and cons of dynamic

More COM Support
COM interop
Ref example
Omit the ref
NoPIA
(No Primary Interop Assemblies)
Embed the Interop.Word types
The Interop.Word assembly had been removed
The publisher of COM creates PIA

Covariance & Contravariance
Covariace example
Define your own covariant type
Covariant example
Contravariance
Contravariance allows conversions

Events in C#4
Syntax for events
Events prior C#4
What is behind the event keyword?
What is the Methodimpl attribute?
The lock (this)
The C#4 MSIL for events
Collections in .NET
Two Groups of Collections in .NET
Choose System.Collections class
Random Access Collections
Stack
Queue
LinkedList<>
Hashtable
ArrayList
List<>
StringCollection
StringDictionary
SortedList
Operator Overloading
Overloading Revisited
Operator Overloading
The Unary Operators
Unary Operator Overloaded
The true and the false
Why overload the true and false
The unary '-' and '+' Operator
The Bitwise Complement Operator ~
Binary Operators
The Binary Overloaded Operators
Comparison Operators
Casting Operators
The explicit casting operator
explicit Conversions
implicit Conversions
ADO.NET Fundamentals
ADO.NET Providers
Add Connection
Server Explorer
Diffences ADO and ADO.NET
Open and Close connections
Connection Practice
Retrieve Data
Bind DataGridView
Invoke the program
Connection Strings in Config file4
Places to Store Data into Config
How to get Data from Congig
Read Data
Handling SqlExceptions
Finding a record
Inserting a new record
Deleting a record
Create a Store Procedure
Invoking a Store Procedure
Write Data to XML
Updating Record
Export to text file
Reading the text file 

Prerequisites

Participants should have practical experience in a programming language such as C++, JAVA, VB, etc,.
Students must also have an understanding of Object Oriented concepts (attended the Object Technology Refresher course and/or familiar with the Object Oriented Paradigm)

Audience

Developers and Programmers

Course Fee

$3000.00 ex GST

Duration

4.0 Days

Structure

Presentations, Demonstrations & Exercises (50% practical). PC-based

Tools


    
    

Material

Deliverable material for this course includes:

  • Certificate of Accomplishment
  • Professionally printed student notes and exercises
  • CD containing original exercises and source code (For PC-based courses only)

For all courses, but particularly PC-based courses, students are encouraged bring their own USB drive to save worked solutions and/or additional reference material.

Terms and Conditions

Please click here to review our terms and conditions before booking on your course