Building a Complete Web Application Using ASP.NET 3.5 & Visual Studio 2008 (Part 1 of 2) Jeff King...

22
  • date post

    20-Dec-2015
  • Category

    Documents

  • view

    215
  • download

    1

Transcript of Building a Complete Web Application Using ASP.NET 3.5 & Visual Studio 2008 (Part 1 of 2) Jeff King...

Page 1: Building a Complete Web Application Using ASP.NET 3.5 & Visual Studio 2008 (Part 1 of 2) Jeff King Program Manager Microsoft Corporation jking@microsoft.com.
Page 2: Building a Complete Web Application Using ASP.NET 3.5 & Visual Studio 2008 (Part 1 of 2) Jeff King Program Manager Microsoft Corporation jking@microsoft.com.

Building a Complete Web Application Using ASP.NET 3.5 & Visual Studio 2008 (Part 1 of 2)Jeff KingProgram ManagerMicrosoft [email protected]

DEV312

Page 3: Building a Complete Web Application Using ASP.NET 3.5 & Visual Studio 2008 (Part 1 of 2) Jeff King Program Manager Microsoft Corporation jking@microsoft.com.

Today’s GoalBuild a web application using:

ASP.NET 3.5Visual Studio 2008IIS 7.0

Primarily demo and code drivenPlease ask questions and make it interactive!

Provide you with a broad understanding of some of the great new features shipping later this year

Page 4: Building a Complete Web Application Using ASP.NET 3.5 & Visual Studio 2008 (Part 1 of 2) Jeff King Program Manager Microsoft Corporation jking@microsoft.com.

Multi-Targeting Support in VS 2008

New HTML Designer and CSS Support

LINQ and Object Relational Mapping

New ASP.NET Data Controls

Features Covered (Part 1)

Page 5: Building a Complete Web Application Using ASP.NET 3.5 & Visual Studio 2008 (Part 1 of 2) Jeff King Program Manager Microsoft Corporation jking@microsoft.com.

JavaScript IntelliSense and Debugging Support

ASP.NET AJAX and the AJAX Extenders

IIS 7.0 Administration and Security Integration

Features Covered (Part 2)

IIS 7.0 Extensibility Opportunities

Page 6: Building a Complete Web Application Using ASP.NET 3.5 & Visual Studio 2008 (Part 1 of 2) Jeff King Program Manager Microsoft Corporation jking@microsoft.com.

VS 2008 Multi-Targeting Support

Visual Studio 2008 supports targeting multiple versions of the .NET FrameworkChoose which Framework version to target when opening or creating an application

.NET Framework 2.0

.NET Framework 3.0

.NET Framework 3.5

Visual Studio IDE only shows feature appropriate for your selected target version

Toolbox, Add New Item, Add Reference, IntelliSense

Page 7: Building a Complete Web Application Using ASP.NET 3.5 & Visual Studio 2008 (Part 1 of 2) Jeff King Program Manager Microsoft Corporation jking@microsoft.com.

VS 2008 Multi-Targeting Support

demo

Page 8: Building a Complete Web Application Using ASP.NET 3.5 & Visual Studio 2008 (Part 1 of 2) Jeff King Program Manager Microsoft Corporation jking@microsoft.com.

VS 2008 HTML DesignerMassively improved HTML designer

Same WYSIWYG designer engine as in Expression Web

New capabilities:Fast designer/source switchingSplit view designerNested master pagesRich CSS editing support

Enable better designer/developer workflow

Page 9: Building a Complete Web Application Using ASP.NET 3.5 & Visual Studio 2008 (Part 1 of 2) Jeff King Program Manager Microsoft Corporation jking@microsoft.com.

Split View EditorCSS Design SupportNested Master Pages

demo

Page 10: Building a Complete Web Application Using ASP.NET 3.5 & Visual Studio 2008 (Part 1 of 2) Jeff King Program Manager Microsoft Corporation jking@microsoft.com.

Free CSS Web Templates

www.opensourcetemplates.org

Page 11: Building a Complete Web Application Using ASP.NET 3.5 & Visual Studio 2008 (Part 1 of 2) Jeff King Program Manager Microsoft Corporation jking@microsoft.com.

Working with Data

Querying and manipulating data has always been a fundamental part of our jobs as programmers

Data formats change, but core needs are the same

Page 12: Building a Complete Web Application Using ASP.NET 3.5 & Visual Studio 2008 (Part 1 of 2) Jeff King Program Manager Microsoft Corporation jking@microsoft.com.

USE empl

REPLACE ALL salary WITH (salary * 1.1) FOR supervises > 0

LIST ALL fname, lname, salary FOR Supervises > 0

Data Access(DBASE circa 1980s)

• Data querying and manipulation a core part of the programming model experience

• Certainly had limitations, but it sure was useful

Page 13: Building a Complete Web Application Using ASP.NET 3.5 & Visual Studio 2008 (Part 1 of 2) Jeff King Program Manager Microsoft Corporation jking@microsoft.com.

SqlCommand cmd = new SqlCommand( @"SELECT fname, lname, salary

FROM Empl WHERE supervises > @p0"

);

cmd.Parameters.AddWithValue("@po", 0);

SqlConnection c = new SqlConnection(…); c.Open(); DataReader people = c.Execute(cmd);

while (people.Read()) { string fname = (string) people[“fname”]; string lname = (string) people[“lname”]; double salary = (double) people[“salary”]; } dr.Close();

Data Access APIs(circa late 1990s/early 2000s)

Page 14: Building a Complete Web Application Using ASP.NET 3.5 & Visual Studio 2008 (Part 1 of 2) Jeff King Program Manager Microsoft Corporation jking@microsoft.com.

Object / Relational Mapping(circa last few years)

public class Employee { public string FirstName; public string LastName; public double Salaray; } IList employees = session.CreateCriteria(typeof(Employee)) .Add(Expression.Gt(“supervises", 0) .List();

foreach(Employee employee in employees) { string fname = employee.FirstName; string lname = employee.LastName; double salary = employee.Salary; }

• Map relational data to/from objects• Cleaner integration of business rules and

validation

Page 15: Building a Complete Web Application Using ASP.NET 3.5 & Visual Studio 2008 (Part 1 of 2) Jeff King Program Manager Microsoft Corporation jking@microsoft.com.

But Challenges Still Remain…

How to retrieve non-relational data?XML, RSS, Web Services, REST, AD, Files, etc.

How to interact with plain old objects?How do you interact and query custom domain models?

How to enable rich data shaping & transformations?

Support flexible query composition (that is fast!)

How to enable clean code in both a strongly typed and dynamic language world?

Page 16: Building a Complete Web Application Using ASP.NET 3.5 & Visual Studio 2008 (Part 1 of 2) Jeff King Program Manager Microsoft Corporation jking@microsoft.com.

LINQQuery, Set and Transform Operations for .NET

Makes querying data a core programming concept

Works with all types and shapes of dataRelational databasesXMLPlain old Objects

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

Page 17: Building a Complete Web Application Using ASP.NET 3.5 & Visual Studio 2008 (Part 1 of 2) Jeff King Program Manager Microsoft Corporation jking@microsoft.com.

New ASP.NET Data Controls

<asp:ListView>

<asp:LinqDataSource>

<asp:DataPager>

Page 18: Building a Complete Web Application Using ASP.NET 3.5 & Visual Studio 2008 (Part 1 of 2) Jeff King Program Manager Microsoft Corporation jking@microsoft.com.

LINQLINQ to SQL <asp:ListView> <asp:LinqDataSource>

demo

Page 19: Building a Complete Web Application Using ASP.NET 3.5 & Visual Studio 2008 (Part 1 of 2) Jeff King Program Manager Microsoft Corporation jking@microsoft.com.

IntermissionMore coming in Part 2:

AJAX:JavaScript IntelliSense and DebuggingASP.NET AJAXASP.NET AJAX Control Extenders

IIS7 and ASP.NET IntegrationSecurity integrationExtensibility Opportunities

Page 20: Building a Complete Web Application Using ASP.NET 3.5 & Visual Studio 2008 (Part 1 of 2) Jeff King Program Manager Microsoft Corporation jking@microsoft.com.

Evaluation Forms

Page 21: Building a Complete Web Application Using ASP.NET 3.5 & Visual Studio 2008 (Part 1 of 2) Jeff King Program Manager Microsoft Corporation jking@microsoft.com.

Questions?

Page 22: Building a Complete Web Application Using ASP.NET 3.5 & Visual Studio 2008 (Part 1 of 2) Jeff King Program Manager Microsoft Corporation jking@microsoft.com.

© 2007 Microsoft Corporation. All rights reserved. Microsoft, Windows, Windows Vista and other product names are or may be registered trademarks and/or trademarks in the U.S. and/or other countries.

The information herein is for informational purposes only and represents the current view of Microsoft Corporation as of the date of this presentation. Because Microsoft must respond to changing market conditions, it should not be interpreted to be a commitment on the part of Microsoft, and Microsoft cannot guarantee the accuracy of any information provided after

the date of this presentation. MICROSOFT MAKES NO WARRANTIES, EXPRESS, IMPLIED OR STATUTORY, AS TO THE INFORMATION IN THIS PRESENTATION.