Introduction In The Name Of Allah, The Beneficent, The Merciful.

Post on 02-Jan-2016

214 views 0 download

Tags:

Transcript of Introduction In The Name Of Allah, The Beneficent, The Merciful.

Introduction

www.CSharpSchool.blog.ir

In The Name Of Allah, The Beneficent, The Merciful

C#

Contents

• Visual Studio 2012 IDE• Creating Applications– Console Application– Windows Forms Application– ASP.NET Web Page

• C# and the .NET Framework

2

Setting the Visual C# Settings

3

Visual C# Keyboard Settings

• After installing Visual Studio 2012, select the Visual C# Settings from the Default Collection of Settings window.

• This sets the keyboard commands and the user interface for the C# environment.– Run: Ctrl-F5, Debug: F5, Build: Ctrl-Shift-B, etc.– New Website command in the Start Page if you select Web

Development settings.• If you miss the window, or select another setting, then

select the command Import and Export Settings from the Tools menu.

4

5

6

7

8

Creating a Console Application

9

10

11

12

13

Write the code and press Ctrl-F5

14

Creating a Windows Forms Application

15

16

17

18

Drag & drop a label and button onto the form

19

Double-click the button

20

Write the code and press Ctrl-F5

21

Click the button

Creating an ASP.NET Web Page

22

23

Do NOT select File -> New ->

Project -> ASP.NET Web

Forms Application

24

25

Right-click the project name and select Add -> Add New Item

(equivalently: Add -> Web Form)

26

27

Switch to Design View

28

Put a Label, press the Enter key, and put a Button

29

Double-click the button

30

Write the code and press Ctrl-F5

31

Click the button

32

Visual Studio 2012

• A powerful integrated development environment (IDE)• Automates the steps required to compile source code• Intelligently detect errors and suggest code where

appropriate as you are typing (Intellisense)• Includes designers, enabling simple drag&drop design of

UI elements• Includes starter projects• Enables deployment• Enables debugging• etc.

33

Visual Studio Solutions

• You create solutions in Visual Studio• Solutions contain projects• Solutions can contain multiple projects– This enables you to work on shared code

34

35

Solution Explorer

Properties Window

Toolbox Designer

36

Source Code

SolutionProjectSource

Files

با تشکر از توجه شما

عبداله صارمی نایینی1393

پایان