+ All Categories
Home > Documents > whatsnewasp3.5part1

whatsnewasp3.5part1

Date post: 02-Apr-2018
Category:
Upload: balus143
View: 221 times
Download: 0 times
Share this document with a friend

of 24

Transcript
  • 7/27/2019 whatsnewasp3.5part1

    1/24

    ASP.NET 3.5 New Features

  • 7/27/2019 whatsnewasp3.5part1

    2/24

    2

    Agenda

    What's New in .NET Framework 3.5?

    Visual Studio 2008 Enhancements

    LINQ (Language Integrated Query)

    New ASP.NET Server Controls

    ASP.NET 3.5 Extensions

    ASP.NET Dynamic Data ( now in SP1 )

    ASP.NET MVC Framework ( now in Beta )

    ASP.NET and AJAX Integration

    ASP.NET Controls for Silverlight

  • 7/27/2019 whatsnewasp3.5part1

    3/24

  • 7/27/2019 whatsnewasp3.5part1

    4/24

    4

    Whats New in .NET Framework 3.5?

    Language Integrated Queries (LINQ)

    Family of technologies that provides querying features

    for data, from relational to XML

    Generate a LINQ object model that provides an objectrepresentation of the database

    New collections: HashSet

    Peer-to-Peer networking framework

    Integration of WCF and WWF (Workflow

    Services)

  • 7/27/2019 whatsnewasp3.5part1

    5/24

    5

    Whats New in Visual Studio 2008?

    Framework targeting (2.0, 3.0, 3.5)

    Full support for LINQ and LINQ to SQL

    Integrated ASP.NET AJAX

    Improved HTML editor Split source/design view

    JavaScript IntelliSense and debugging

    CSS manager and debugger

    Integrated WPF, WCF, WF designers

    Runs a bit slower

  • 7/27/2019 whatsnewasp3.5part1

    6/24

    6

    Visual Studio 2008 Enhancements

    Multi-Targeting

    Nested Master Pages

    Fast Switching

    Split View

    CSS Tools

    Control Extender

    Support

    JS Intellisense

    JS Debugging

    VisualStudio 2008

  • 7/27/2019 whatsnewasp3.5part1

    7/247

    LINQ and LINQ to SQL

    Query, set and transform operations for .NET

    Querying data becomes a core programming concept

    Works with all types and shapes of data Relational databases

    XML Objects

    Works with all .NET languages C# and VB and have integrated language support

    LINQ to SQL Powerful ORM framework

  • 7/27/2019 whatsnewasp3.5part1

    8/248

    var contacts =from c in customers

    where c.State == "WA"

    select new { c.Name, c.Phone };

    var contacts =

    customers

    .Where(c => c.State == "WA")

    .Select(c => new { c.Name, c.Phone });

    Extensionmethods

    Lambdaexpressions

    Queryexpressions

    Objectinitializers

    Anonymoustypes

    Local variabletype inference

    Expressiontrees

    Automaticproperties

    Partialmethods

  • 7/27/2019 whatsnewasp3.5part1

    9/249

    Implicitly typed locals Extension methods

    Lambda Expressions

    Object initializers Anonymous types

    Nullable types

    Query expressions XML Literals

    Dim x = 5

    Sub Randomize(col As Collection)

    Function(c) c.Name

    New Point With { .x = 1, .y = 2 }

    New With { c.Name, c.Phone }

    From Where Select

  • 7/27/2019 whatsnewasp3.5part1

    10/2410

    SqlConnection c = new SqlConnection();

    c.Open();

    SqlCommand cmd = new SqlCommand(

    @"SELECT c.Name, c.Phone

    FROM Customers c

    WHERE c.City = @p0");

    cmd.Parameters["@p0"] = "London";

    DataReader dr = c.Execute(cmd);

    while (dr.Read()) {

    string name = dr.GetString(0);string phone = dr.GetString(1);

    DateTime date =dr.GetDateTime(2);

    }

    dr.Close();

    Queries inquotes

    Loosely boundarguments

    Loosely typed

    result sets

    No compile timechecks

  • 7/27/2019 whatsnewasp3.5part1

    11/2411

    public class Customer { }

    public class Northwind: DataContext

    {

    public Table Customers;

    }

    Northwind db = new Northwind();

    var contacts =

    from c in db.Customerswhere c.City == "London"

    select new { c.Name, c.Phone };

    Classes describedata

    Strongly typedconnection

    Integrated query

    syntax

    Strongly typedresults

    Tables are likecollections

  • 7/27/2019 whatsnewasp3.5part1

    12/2413

    LINQ to SQL

    LINQ to SQL

    Designer in

    VS 2008

    NorthwindDataContext db =

    new NorthwindDataContext();

    var customers = from c in db.Customers

    where c.City == "London" select c;

    foreach (var cust in customers)Console.WriteLine(

    "id = {0}, City = {1}",

    cust.CustomerID, cust.City);

  • 7/27/2019 whatsnewasp3.5part1

    13/2414

    LINQ to Objects API queries over any .NET collection, such as arrays and generic

    lists.

    LINQ over XML (XLinq) Core functionality of the XLinq API such as load, modify, and

    save XML documents LINQ to SQL

    provides direct access to database tables from theprogramming environment

    LINQ to Entities

    enables developers to use LINQ over EDM models LINQ to Dataset

    allows the full expressivity of LINQ to be used over Datasets.

  • 7/27/2019 whatsnewasp3.5part1

    14/2415

    New ASP.NET Data Controls

  • 7/27/2019 whatsnewasp3.5part1

    15/2416

    ListView Control

    Combines templating capabilities of the Repeater control and the data editingcapabilities of the DataGrid

    complete control of how the ListView presents your data through 11 templates. LayoutTemplate

    AlternatingItemTemplate

    EditItemTemplate

    EmptyDataTemplate

    EmptyItemTemplate

    GroupTemplate

    GroupSeparatorTemplate

    InsertItemTemplate

    ItemTemplate

    ItemSeparatorTemplate

    SelectedItemTemplate

    most important templates are the LayoutTemplate and the ItemTemplate.

    LayoutTemplate HTML defines the overall look and feel

    ItemTemplate HTML specifies how each bound record will appear.

  • 7/27/2019 whatsnewasp3.5part1

    16/2417

    ListView


  • 7/27/2019 whatsnewasp3.5part1

    17/2418

    DataPager

    provides paging capabilities.

    points at the control it provides paging

    support for. As an external control

    place it anywhere on the page, and configure

    look

    works with controls that implement the

    IPageableItemContainer interface ( ListView )

  • 7/27/2019 whatsnewasp3.5part1

    18/2419

    DataPager

  • 7/27/2019 whatsnewasp3.5part1

    19/2420

    LinqData Source Control

    Bind to a Linq Data Model

  • 7/27/2019 whatsnewasp3.5part1

    20/2421

    ASP.NET 3.5 Extensions ASP.NET MVC Framework

    Model View Controller framework for ASP.NET ( now in Beta ) ASP.NET Dynamic Data

    Dynamic data controls for displaying/editing table data in ASP.NET

    ASP.NET AJAX Browser history support

    ADO.NET Data Services Create REST addressable services endpoints for your data and

    consume with AJAX and Silverlight

    Silverlight Controls for ASP.NET Integrate Silverlight into ASP.NET applications

  • 7/27/2019 whatsnewasp3.5part1

    21/2422

    ASP.NET Dynamic Data

    Create quickly a rich data-driven Web sites

    Like in Ruby on Rails and Django (in Python)

    Based on LINQ to SQL data model

    Dynamically display data based on the data model ofthe underlying database

    Pages are created automatically (zero code)

    Based on highly customizable templates

    Uses dynamic data fields user controls that

    render standard data field types

  • 7/27/2019 whatsnewasp3.5part1

    22/2423

    ASP.NET Dynamic Data

  • 7/27/2019 whatsnewasp3.5part1

    23/24

    24

    ASP.NET AJAX

    All AJAX 1.0 features in.NET 3.5 Enhancements to UpdatePanel

    WCF JSON Services Better Development

    Experience JavaScript Intellisense

    JavaScript Debugging ASP.NET AJAX Extender

    Control Support

    ASP.NET 2.0

    VS 2005

    v1.0

    ASP.NET 3.5

    VS 2008

    v1.0 v3.5

  • 7/27/2019 whatsnewasp3.5part1

    24/24

    ASP.NET AJAX Control Toolkit

    Separate download from coreASP.NET AJAX Library of free ASP.NET AJAX

    enabled controls

    Download from http://ajax.asp.net

    Developed using a collaborativesource model Licensed under Microsoft Public

    License (Ms-PL)

    All source freely available

    ~ 40 controls as of today

    http://ajax.asp.net/http://ajax.asp.net/