Introduction to.NET Microsoft announced in June 2000 A new software –development model that allows applications created in disparate programming languages.

Slides:



Advertisements
Similar presentations
Windows Programming 1 Part 1 dbg --- Getting Acquainted with Visual Studio.NET and C#
Advertisements

Visual Basic 2010 How to Program. © by Pearson Education, Inc. All Rights Reserved.2.
Visual Basic 2010 How to Program Reference: Instructor: Maysoon Bin Duwais slides Visual Basic 2010 how to program by Deitel © by Pearson Education,
Introduction to the C# Programming Language for the VB Programmer.
Copyright © 2012 Pearson Education, Inc. Chapter 1: Introduction to Computers and Programming.
Introduction to VC++.NET #include”stdsfx.h” // includes contents of stdsfx.h into this program file #using // references prepackaged Microsoft code Using.
Functions and methods A method is a function that is a member of a class A method is a function that is a member of a class FCL(Framework Class Library)
Visual C++.NET Hong Li. Introduction to.NET Microsoft announced in June 2000 Microsoft announced in June 2000 A new software –development model that allows.
Chapter 3: Introducing the Microsoft.NET Framework and Visual Basic.NET Visual Basic.NET Programming: From Problem Analysis to Program Design.
Chapter 2: The Visual Studio.NET Development Environment Visual Basic.NET Programming: From Problem Analysis to Program Design.
1 An Introduction to Visual Basic Objectives Explain the history of programming languages Define the terminology used in object-oriented programming.
Creating and Running Your First C# Program Svetlin Nakov Telerik Corporation
Tahir Nawaz Visual Programming C# Week 2. What is C#? C# (pronounced "C sharp") is an object- oriented language that is used to build applications for.
An Introduction to C# and the .NET Framework
Rajeswari Indupuri Introduction to.NET Framework.
Microsoft Visual Basic 2012 CHAPTER ONE Introduction to Visual Basic 2012 Programming.
Microsoft Visual Basic 2005 CHAPTER 1 Introduction to Visual Basic 2005 Programming.
1 ENG236: ENG236: C++ Programming Environment (2) Rocky K. C. Chang THE HONG KONG POLYTECHNIC UNIVERSITY.
Copyright © 2012 Pearson Education, Inc. Chapter 1: Introduction to Computers and Programming.
Creating and Running Your First C# Program Telerik Software Academy Telerik School Academy.
Chapter Introduction to Computers and Programming 1.
Introduction 01_intro.ppt
A First Program Using C#
M1G Introduction to Programming 2 4. Enhancing a class:Room.
NOTE: To change the image on this slide, select the picture and delete it. Then click the Pictures icon in the placeholder to insert your own image. WEB.
High thoughts must have high language. Aristophanes
Architecture of.NET Framework .NET Framework ٭ Microsoft.NET (pronounced “dot net”) is a software component that runs on the Windows operating.
Module 1: Introduction to C# Module 2: Variables and Data Types
 2002 Prentice Hall. All rights reserved. 1 Introduction to Visual Basic.NET,.NET Framework and Visual Studio.NET Outline 1.7Introduction to Visual Basic.NET.
.NET Overview. 2 Objectives Introduce.NET –overview –languages –libraries –development and execution model Examine simple C# program.
Introduction to Microsoft.Net Session 01 Mata kuliah: M0874 – Programming II Tahun: 2010.
11 Getting Started with C# Chapter Objectives You will be able to: 1. Say in general terms how C# differs from C. 2. Create, compile, and run a.
Introduction to .NET Framework
Lecture Set 1 Part B: Understanding Visual Studio and.NET – Structure and Terminology 1/16/ :04 PM.
Creating and Running Your First C# Program Svetlin Nakov Telerik Corporation
Copyright © 2012 Pearson Education, Inc. Chapter 1: Introduction to Computers and Programming 1.
Copyright © 2012 Pearson Education, Inc. Chapter 1: Introduction to Computers and Programming.
Chapter 1: Introduction to Computers and Programming.
Copyright © 2009 Pearson Education, Inc. Publishing as Pearson Addison-Wesley Chapter 1: Introduction to Computers and Programming.
2. Introduction to the Visual Studio.NET IDE. Chapter Outline Overview of the Visual Studio.NET IDE Overview of the Visual Studio.NET IDE Menu Bar and.
Lecture Set 2 Part B – Configuring Visual Studio; Configuration Options and The Help System (scan quickly for future reference)
Lecture Set 1 Part C: Understanding Visual Studio and.NET – Applications, Solutions, Projects (no longer used – embedded in Lecture Set 2A)
CS 114 – Class 02 Topics  Computer programs  Using the compiler Assignments  Read pages for Thursday.  We will go to the lab on Thursday.
Tutorial 1: An Introduction to Visual Basic.NET1 Tutorial 1 An Introduction to Visual Basic.NET.
1 Introduction to C# Programming Console applications No visual components Only text output Two types MS-DOS prompt - Used in Windows 95/98/ME Command.
Programming in C#. I. Introduction C# (or C-Sharp) is a programming language. C# is used to write software that runs on the.NET Framework. Although C#
Week 1: THE C# LANGUAGE Chapter 1: Variables and Expressions ➤ Included in Visual Studio.NET ➤ What the.NET Framework is and what it contains ➤ How.NET.
NOTE: To change the image on this slide, select the picture and delete it. Then click the Pictures icon in the placeholder to insert your own image. WEB.
Introduction to .NET Framework
Lecture Set 2 Part A: Creating an Application with Visual Studio – Solutions, Projects, Files.
Applied Computing Technology Laboratory QuickStart C# Learning to Program in C# Amy Roberge & John Linehan November 7, 2005.
Using Microsoft Visual Studio C++ Express 2005 Name: Dr Ju Wang Ashwin Belle Course Resource:
N from what language did C++ originate? n what’s input, output device? n what’s main memory, memory location, memory address? n what’s a program, data?
Module 1: Getting Started. Introduction to.NET and the.NET Framework Exploring Visual Studio.NET Creating a Windows Application Project Overview Use Visual.
1 Introduction to C# Programming Console applications No visual components Only text output Two types MS-DOS prompt - Used in Windows 95/98/ME Command.
Introduction to Visual Basic Programming. Introduction Simple Program: Printing a Line of Text Another Simple Program: Adding Integers Memory Concepts.
1 Programming Environment and Tools VS.Net 2012 First project MSDN Library.
Chapters 2 & 3. .NET Software development model that allows applications created in disparate programming languages to communicate Universal data access.
 2002 Prentice Hall. All rights reserved. 1 Chapter 2 – Introduction to the Visual Studio.NET IDE Outline 2.1Introduction 2.2Visual Studio.NET Integrated.
Getting Started with.NET Getting Started with.NET/Lesson 1/Slide 1 of 31 Objectives In this lesson, you will learn to: *Identify the components of the.NET.
 2001 Prentice Hall, Inc. All rights reserved. 1 Chapter 3 – Introduction to C# Programming Outline 3.1 Introduction 3.2 Simple Program: Printing a Line.
INTRODUCTION CHAPTER #1 Visual Basic.NET. VB.Net General features It is an object oriented language  In the past VB had objects but focus was not placed.
Text Introduction to.NET Framework. CONFIDENTIAL Agenda .NET Training – Purpose  What is.NET?  Why.NET?  Advantages  Architecture  Components: CLR,
Lecture Set 1 Part B: Understanding Visual Studio and.NET – Structure and Terminology 1/16/ :04 PM.
 2002 Prentice Hall. All rights reserved. 1 Introduction to the Visual Studio.NET IDE Outline Introduction Visual Studio.NET Integrated Development Environment.
Chapter 1: Introduction to Computers and Programming.
Module 1: Getting Started
1. Open Visual Studio 2008.
Computer Terms Review from what language did C++ originate?
IS 135 Business Programming
Presentation transcript:

Introduction to.NET Microsoft announced in June 2000 A new software –development model that allows applications created in disparate programming languages to communicate with each other Allows developers to create Web-based applications

Introduction to.NET One key aspect of the.NET strategy is its independence from a specific language or platform Developer can create a.NET application by using any combination of.NET- compatible languages

Introduction to.NET Programmers can contribute to the same software project, writing code in the.NET languages in which they are most proficient Such as Visual C++.NET, C#, Visual Basic.NET and many others

Visual C++.NET Known as a visual programming language-the developer uses graphical tools, such as Visual Studio.NET, to create applications Visual C++ uses MFC.NET provides an additional library for implementing GUI, networking, multithreading and other capabilities

Visual C++.NET Visual C++.NET introduces Managed Extensions for C++ that enable a programmer to access the.NET framework. Programmers can use the.NET to create objects that provide automatic memory management C++ -- standard C++ MC++ -- managed extension to C++ Visual C++.NET – compiler used to write both managed and unmanaged code

How to use Visual Studio.NET IDE( integrated development environment) From Start->program Click Microsoft visualStudio.NET Click New Project to create a new project Or select a recent project on start page Or from file->new to create new project Or from file->open to open an existing project

How to use VisualStudio.NET In pop-up window  select visual C++ projects in left panel  Select Console application in right panel  Give a name to the project by Name  Select a location where project will be created Click OK

To create an unmanaged project ( write a standard C++ code) In pop-up window, Click application setting Select empty project Click finish

To add a source file: From file->new->files Or from solution explore window, right click on source file and select add->add new item (If you don’t see solution explore window, from view- >solution explore) In pop-up window, click C++ file(.cpp), name the file and select a location and then click open.

Create a window project From File->new ->project Select Windows form application Name the project, select a location then click ok.

Compile, build and exectute To compile a.cpp file, Click build->compile To build the project Click build->Build Solution To execute Click Debug->start without Debugging (You can run debug when you need to)

A simple program #include “stdafx.h” #using #using namespace System; int _tmain() { Console::WriteLine(S”Welcome”); return 0; }// end of _tmain

A simple Program #include”stdsfx.h” // includes contents of stdsfx.h into this program file #using // references prepackaged Microsoft code using namespace System; // declares the use of namespace System

namespace A namespace groups various MC++ features into related categories. The namespace that are defined in the.NET Framework contain preexisting code known as the.NET Framework Class Library(FCL). The actual code for the classes is located in.dll files called assemblies. The using directive informs your program that you intend to use a namespace using namespace System; This using directive allows us to write Console::WriteLine(S”Hello”); rather than System::Console::WriteLine(S”Hello”);

Namespaces in MC++ Systemessential class and types System::Dataclasses form ADO.NET, used for database access and manipulation System::Drawingclasses used for drawing and graphic System::IOclasses for input and output of data System::Threadingclasses for multithreading, used to run multiple parts of a program simultaneously System::Windows::Formsclasses used to create GUI System::Xmlclasses used to process XML data

Console class A example of one of the features in namespace System is class Console The Console class enables programs to output information to the computer’s standard output. Class Console provides methods, such as method WriteLine, that allow MC++ program to display strings and other types of information in the windows console window

S The S prefix indicates that the string that follows is a string-literal in the Managed Extensions for C++ Write(S”..”); WriteLine(S” …”); ReadLine(); //read a string from keyboard

Another program int _tmain() { String *Firstnum; String *Secondnum; int num1, num2, sum; Console::Write(S”Enter first integer”); Firstnum = Console::ReadLine(); Console::Write(S”Enter second integer”); Secondnum=Console::ReadLine(); num1 = Int32::Parse(Firstnum); num2 = Int32::Parse(Secondnum); sum = num1+num2; Console::WriteLine(S”\nThe sum is {0}.”, sum.ToString()); return 0; }

FCL Structure/class name Int16 16 bit signed integer short Int32 32-bit signed integer int Int64 64-bit integer __int64 Single 32-bit float Double 64-bit double Boolean boolean value bool Char Unicode(16-bit)character String string of unicode characters String*