Добавил:
Upload Опубликованный материал нарушает ваши авторские права? Сообщите нам.
Вуз: Предмет: Файл:
C# 2008 Step by Step.pdf
Скачиваний:
26
Добавлен:
25.03.2016
Размер:
13.96 Mб
Скачать

586

Part VI Building Web Applications

If you want to continue to the next chapter

Keep Visual Studio 2008 running, and turn to Chapter 28.

If you want to exit Visual Studio 2008 now

On the File menu, click Exit. If you see a Save dialog box, click Yes and save the project.

Chapter 27 Quick Reference

To

Do this

Create a Web application

Create a new Web site using the ASP.NET Web Site template. Specify

 

whether you want to use the Development Server (specify a file system

 

location and file name) or IIS (specify an HTTP location and URL).

View and edit the HTML definition of a Web form

Click the Source button in the Design View window.

Create a style for a Web form

In the Manage Styles window, click New Style. Use the New Style dialog

 

box to define the style for the form.

 

 

Add ASP.NET Server controls to a

Click the Design button in the Design View window. In the Toolbox,

Web form

expand the Standard category. Drag controls onto the Web form.

 

 

Add HTML controls to a Web form

In the Toolbox, click the HTML category. Drag controls onto the Web

(with HTML controls, you can more

form.

easily port existing ASP pages into

 

ASP.NET)

 

Create an event handler for an ASP. NET Server control

In the Design View window, select the control on the Web form. In the Properties window, click the Events button. Choose the event you want

to handle and type the name of an event handler method or doubleclick the event name to select the default name. In the Code and Text Editor window, write the code to handle the event.

Create a theme

Add an App_Themes folder to the Web site. Create a subfolder for

 

the theme. Create a skin file defining the properties of controls in this

 

folder.

 

 

Apply a theme to a Web site

Either specify the theme using the @Page attribute of each page, like

 

this:

 

<%@Page Theme=”BlueTheme” ...%>

 

or modify the web.config file and specify the theme in the pages

 

element, like this:

<pages theme=”BlueTheme”>

Соседние файлы в предмете [НЕСОРТИРОВАННОЕ]