Вы находитесь на странице: 1из 19

Introduction to Microsoft .

Net /
Silverlight Platform

Developer Designer Productivity

Designers design

Microsoft Tools for Designers &


Developers

Declarative Programming through


XAML
developers can streamline

Third Party Tools

With XAML designers &

their collaboration
Developers add business logic

Developers Visual Studio

Designers Expression Blend

Syntax
Programming Syntax C# or VB.Net
UI Markup Extensible Application Markup Language
(XAML)
Static storage Extensible Markup Language (XML)

Predefined Types

String
Integer
Double
Boolean
Decimal
And many others

Syntax Define variable name and types


C#
int _age = 0;

VB.Net
dim _age as integer = 0

Syntax Define variable name and custom


types
C#
person _michael = null;

VB.Net
dim _michael as person = nothing

Control Flows
Conditional Statements
If-Else

Iteration Statements

Do
For
Foreach
while

Syntax if - else
C#

If (_age > 20)


{
//do something
}
Else
{
//do something
}

VB.Net

If _age > 20 then


do something
Else
do something
End if

Syntax Do
C#
do
{
// do something
// _age ++;
} while (_age<5);

VB.Net
do while _age <5
//do something
// _age = _age + 1
loop

Syntax For
C#
For {int i=0; i < _age; i++)
{
// do something
}

VB.Net
for i =0 to _age
//do something
next

Syntax Foreach
C#
foreach {int i in numberList )
{
// do something
}

VB.Net
for each i as integer in numberList
// do something
next

Syntax while
C#
While (_age <10)
{
// do something
// _age++
}

VB.Net
While (_age <10)
//do something
// _age = _age + 1
End while

Collections
Used for grouping and managing objects
Index and Key Values allow developers to access item
Collections allow

Add
Remove
Clear
Count
Contains
Items

Collections
List(of type)
Represents a strongly typed list of objects that can be accessed
by index. Provides methods to search, sort, and manipulate lists.
List(of String)

Dictionary
Represents a collection of keys and values.
Dictionary(of String, String)

ObservableCollections
Represents a dynamic data collection that provides notifications
when items get added, removed, or when the whole list is
refreshed.
ObservableCollection(of String)

Developer Tool Capabilities


Syntax Intellisense
Debugging

Breakpoint
Condition debugging
Hit count
Filters

Quick Search and Quick Replace


Goto and NavigateTo
Built-in MarketPlace test Kit
And etc..

Designer Tool Capabilities

Interactive designing tools


Animation composer
Object window
State window
Data window
Search controls toolbox
Resource Dictionary Panel
And etc

Conclusion

Developer Tools Visual Studio2 010


Designer Tools Expression Blend 4.0, Adobe Illustrator
Application Development Language VB.Net or C#
Silverlight UI Markup XAML

Вам также может понравиться