1 Chapter 20 — Creating Web Projects Microsoft Visual Basic.NET, Introduction to Programming.

Slides:



Advertisements
Similar presentations
Chapter 3 – Web Design Tables & Page Layout
Advertisements

11 Getting Started with ASP.NET Beginning ASP.NET 4.0 in C# 2010 Chapters 5 and 6.
Web Forms and ASP.NET Programming Right from the Start with Visual Basic.NET 1/e 12.
The Web Warrior Guide to Web Design Technologies
Hypertext Markup Language. Platform: - Independent  This means it can be interpreted on any computer regardless of the hardware or operating system.
Web Development in Microsoft Visual Studio Slide 2 Lecture Overview Introduce Visual Studio 2013 Create a first ASP.NET application.
1 Chapter 12 Working With Access 2000 on the Internet.
XP Browser and Basics1. XP Browser and Basics2 Learn about Web browser software and Web pages The Web is a collection of files that reside.
ASP Tutorial. What is ASP? ASP (Active Server Pages) is a Microsoft technology that enables you to make dynamic and interactive web pages. –ASP usually.
Chapter 12: ADO.NET and ASP.NET Programming with Microsoft Visual Basic.NET, Second Edition.
Chapter 2: The Visual Studio.NET Development Environment Visual Basic.NET Programming: From Problem Analysis to Program Design.
Chapter 14: Advanced Topics: DBMS, SQL, and ASP.NET
Computer Arithmetic: Binary, Octal and Hexadecimal Presented by Frank H. Osborne, Ph. D. © 2005 ID 2950 Technology and the Young Child.
Browser and Basics Tutorial 1. Learn about Web browser software and Web pages The Web is a collection of files that reside on computers, called.
1 An Introduction to Visual Basic Objectives Explain the history of programming languages Define the terminology used in object-oriented programming.
Computer Science 101 Web Access to Databases Overview of Web Access to Databases.
Mgt 240 Lecture Website Construction: Software and Language Alternatives March 29, 2005.
THE BASICS OF THE WEB Davison Web Design. Introduction to the Web Main Ideas The Internet is a worldwide network of hardware. The World Wide Web is part.
XP New Perspectives on Microsoft Access 2002 Tutorial 71 Microsoft Access 2002 Tutorial 7 – Integrating Access With the Web and With Other Programs.
DAT602 Database Application Development Lecture 15 Java Server Pages Part 1.
Microsoft Visual Basic 2005 CHAPTER 12 Cell Phone Applications and Web Services.
Getting Started with Dreamweaver
Chapter 9 Web Applications Copyright © 2011 by The McGraw-Hill Companies, Inc. All Rights Reserved. McGraw-Hill.
 Using Microsoft Expression Web you can: › Create Web pages and Web sites › Set what you site will look like as you design it › Add text, images, multimedia.
INTRODUCTION TO WEB DATABASE PROGRAMMING
Introduction to.Net and ASP.Net Course Introduction Build Your Own ASP.Net Website: Chapter 1 Microsoft ASP.Net Walkthrough: Creating a Basic Web Forms.
9-1 aslkjdhfalskhjfgalsdkfhalskdhjfglaskdhjflaskdhjfglaksjdhflakshflaksdhjfglaksjhflaksjhf.
Tutorial: Introduction to ASP.NET Internet Technologies and Web Application 4 th February 2010.
Architecture Of ASP.NET. What is ASP?  Server-side scripting technology.  Files containing HTML and scripting code.  Access via HTTP requests.  Scripting.
CIS 375—Web App Dev II ASP.NET 2 Introducing Web Forms.
Database-Driven Web Sites, Second Edition1 Chapter 8 Processing ASP.NET Web Forms and Working With Server Controls.
Dr. Azeddine Chikh IS444: Modern tools for applications development.
Object-Oriented Application Development Using VB.NET 1 Chapter 12 Web Forms, HTML, and ASP.NET.
Chapter 1: Introduction to Web
Basics of Web Databases With the advent of Web database technology, Web pages are no longer static, but dynamic with connection to a back-end database.
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.
Overview of Previous Lesson(s) Over View  ASP.NET Pages  Modular in nature and divided into the core sections  Page directives  Code Section  Page.
Microsoft Visual Basic 2005: Reloaded Second Edition
Programming with Microsoft Visual Basic 2012 Chapter 12: Web Applications.
XP New Perspectives on Browser and Basics Tutorial 1 1 Browser and Basics Tutorial 1.
Creating Web Applications Using ASP.NET Chapter Microsoft Visual Basic.NET: Reloaded 1.
Copyright © 2008 Pearson Prentice Hall. All rights reserved. 1 Exploring Microsoft Office Word 2007 Chapter 8 Word and the Internet Robert Grauer, Keith.
Chapter 9 Programming with Web Forms Programming In Visual Basic.NET.
ASP.NET Web Application and Development Digital Media Department Unit Credit Value : 4 Essential Learning time : 120 hours Digital.
Web Programming: Client/Server Applications Server sends the web pages to the client. –built into Visual Studio for development purposes Client displays.
Tutorial 121 Creating a New Web Forms Page You will find that creating Web Forms is similar to creating traditional Windows applications in Visual Basic.
CSCI 6962: Server-side Design and Programming Introduction to Active Server Pages.
Microsoft FrontPage 2003 Illustrated Complete Using Office Components.
ASP.NET.. ASP.NET Environment ASP.NET is Microsoft's programming framework that enables the development of Web applications and services. It is an easy.
McGraw-Hill © 2009 The McGraw-Hill Companies, Inc. All rights reserved. Programming with Visual Web Developer Chapter 9.
Murach’s ASP.NET 4.0/VB, C1© 2006, Mike Murach & Associates, Inc.Slide 1.
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.
Active Server Pages  In this chapter, you will learn:  How browsers and servers interacted on the Internet when the Internet first became popular 
Kingdom of Saudi Arabia Ministry of Higher Education Al-Imam Muhammad Ibn Saud Islamic University College of Computer and Information Sciences Chapter.
Introduction to ASP.NET T.Ahlam Algharasi. The Visual Studio IDE Start page 2.
Week Developing Web Applications 12. Programming for the Web A Web Application Runs on a Web Server and Presents Its Content to the User Across a Network,
1 WWW. 2 World Wide Web Major application protocol used on the Internet Simple interface Two concepts –Point –Click.
BlackBerry Applications using Microsoft Visual Studio and Database Handling.
Visual Basic for Application - Microsoft Access 2003 Programming applications using Objects.
8 Chapter Eight Server-side Scripts. 8 Chapter Objectives Create dynamic Web pages that retrieve and display database data using Active Server Pages Process.
Chapter 27 Getting “Web-ified” (Web Applications) Clearly Visual Basic: Programming with Visual Basic nd Edition.
XP New Perspectives on Macromedia Dreamweaver MX 2004 Tutorial 5 1 Adding Shared Site Elements.
Chapter 2: The Visual Studio.NET Development Environment Visual Basic.NET Programming: From Problem Analysis to Program Design.
Visual Basic.NET Comprehensive Concepts and Techniques Chapter 11 Creating Web Applications and Writing Data to a Database.
ASP.NET Forms.
Web Forms, HTML, and ASP.NET
WEB PROGRAMMING JavaScript.
Tutorial 7 – Integrating Access With the Web and With Other Programs
Programming with Microsoft Visual Basic 2008 Fourth Edition
Presentation transcript:

1 Chapter 20 — Creating Web Projects Microsoft Visual Basic.NET, Introduction to Programming

2 Important The projects –ASP.NET in this lesson can be in: a Web server running Microsoft Internet Information Services (IIS) server FTP server Local File Drive.

3 Objectives Create an ASP.NET Web Application project. Mix both Web forms server controls and standard HTML controls on a Web page. Work with grid layout and flow layout modes in the Web forms Designer. Populate an HTML table with data generated from code in a Web page. Manipulate dates.

4 Vocabulary ASP.NET Code-behind file Grid layout mode Flow layout mode Platform Server controls Web forms Web server

5 Putting Projects on the Web Hypertext Markup Language (HTML) is used to build Web pages. It is a language that is at the same time both simple and sophisticated. To get an idea of what HTML is like, open any Web page in Internet Explorer and click View | Source. The HTML source used to build the page you see in the browser is shown in a simple text editor. When you request a Web page, the HTML source is used by the Web server to build the page and send it to your machine. The Web server is the computer used to process Web page requests. The server is part of the network of computers that form the Internet.

6 ASP.NET Microsoft’s solution for putting applications on the Web is built around ASP.NET. ASP stands for Active Server Pages. Active server pages are Web pages whose display is actively managed and altered by the Web server. ASP.NET is a platform from which Web applications are run. A platform is the combination of hardware and operating system on which applications are run. ASP.NET contains controls and objects with which to build Web pages, as well as a run-time system that executes the pages on the Web server. For database access, ASP.NET uses ADO.NET, the same system you have already used in this book to access databases.

7 Web Application To create a Web application using Visual Basic, open a new ASP.NET Web Application project using its template in the New Project window.

8 Web Forms A Web project is composed of static HTML pages, like the HTML file you created in Lesson 13, and Web forms. Web forms are built from the ASP.NET Page class. Objects created with this class are containers for controls and HTML. The controls placed on Web forms are part of the ASP.NET framework and provide the kind of functionality you are used to seeing in interactive Web pages. The controls and other graphic elements of the Web form are contained in an.aspx file. The code that runs the show is contained in a second file, a class file with extension.vb.

9 Grid Layout Mode The WYSIWYG (what you see is what you get) view, grid layout mode, is the actual appearance of the Web form. This view, although somewhat different from the environment you have used to create Windows applications, is the easiest to use. You position controls on the form just as you did for Windows forms.

10 Flow Layout Mode Flow layout mode shows the HTML code that’s executed from top to bottom to build the appearance of the Web page. You may work on the design of the form in either view or switch between the views. If you make a change in one view, the changes you make will be immediately visible when you switch to the other view.

11 Server Controls The controls added to a Web form are called server controls. These controls are similar to the Toolbox controls you add to a Windows form. However, server controls differ from those you add to a Windows form in that they are run on the Web server, Local Drive, FTP server after the Web page is posted to the client’s computer.

12 New Project Window Showing the Selection of ASP.NET Web Application

13 Solution Explorer Showing Files Created for the Amortization Table Web Application

14 Note Although the names of the HTML controls and the Web Forms server controls may seem to indicate overlapping functions, HTML controls are not executed by the server unless they are intentionally converted to server controls.

15 Note Click Build and Browse any time you want to see the effect of your changes on the current version of the Web page.

16 Note The color number, 9933cc, is expressed in base 16, hexadecimal notation. The first two digits, 99, refer to the amount of red in the color. The second two digits, 33, refer to the amount of green. The last two digits, cc, refer to the amount of blue. In base 16, the letter c represents the single digit number, 12. Each pair of digits can express values from 0 to 255, giving 256 levels of red, green, and blue. Each pair of hexadecimal digits is equivalent to 8 binary digits, or bits. Together, each color is specified as a 24-bit value.

17 Amortization Web Page Showing Final Placement of Controls

18 Amortization Web Page Displaying a Monthly Payment of $672.09

19 Amortization Web Page Running in a Browser

20 Adding a Table to a Web Page The tag creates a table with no rows and no cells. Information in the table must appear in a cell which, in turn, must appear in a row. Like other Visual Basic controls, a table is built from a collection — a collection of rows. Each row is a collection of cells.

21 Tables The following statements would add a table to the Web page, but you would not be able to position the table on the page in any particular place. This is the first cell of Row 1 This is the second cell

22 Table Tag

23 Result of Adding a Few Attribute Values to the Tag

24 Turning an HTML Control into a Server Control To turn an HTML table into a server control, add the following attributes to the tag: id="tblAmort" runat="server"

25 Dealing with Dates The Date data type represents both dates and times. The range of possible dates is from January 1, the year 1 to December 31, the year To assign a particular date to a date variable, enclose the date of the form m/dd/year with number signs (#). Dim TodaysDate As Date TodaysDate = #5/27/2002#

26 Dealing with Dates The first statement below shows the declaration and initialization of CurrentDate, the date variable. The second line writes the current date into the innerText property of the HTML Cell. Dim CurrentDate As Date = Now tCell1.InnerText = Format(CurrentDate, "long date")

27 Programming Skills To create a new project, but reuse an existing Web page, first delete the default Web page from the new project by right-clicking the page in the Solution Explorer and clicking Delete. Select Project | Add Existing Item from the menu bar and navigate to the wwwroot directory where server pages are kept. Find the project that contains the existing Web page you want to add to the new project, click Open to add the item, then close the Add Existing Item dialog box. In the Solution Explorer, right-click the newly added Web page (it should have an.aspx extension) and click Set As Start Page.

28 Note The position and spacing of the attributes does not effect the interpretation of the HTML code. Often, each attribute is listed on a separate line. This enhances readability and does not effect the execution of the code.

29 The Amortization Table Project

30 Summary Web servers are computer hardware and special software used to respond to user requests for Web pages. When a Web page is requested by a user, the Web server uses the page's HTML code to build the page and then sends the page to the user's machine. ASP.NET is the platform from which Web applications are run. ASP.NET includes the controls and objects from which Web pages are built, as well as the run-time system needed to execute the code on the pages created. ASP.NET is part of the.NET framework and thus has access to everything available within that framework, including ADO.NET, which is used to access databases.

31 Summary A Web form is a container for controls and other graphic elements. It is built from the ASP.NET Page class. Server controls are controls placed on a Web form. When a client calls on the control to execute code, the code is executed on the Web server. Turn an HTML control into a server control by including the attribute runat = "server" in the control’s opening tag. To refer to the server control in program code, the control's ID property must be set.

32 Summary The DateAdd(DateInterval, Interval (as Integer), Date Variable) function adds an interval to a date and returns a date value.