Chapter1 _Getting Started with ASP.net 4
Chapter1 _Getting Started with ASP.net 4
DOTNET ( ASP)
Visual
Web Developer is a sophisticated
program for creating, editing, and testing
ASP.NET websites and web.
What Is ASP.NET?
website, the Solution Explorer will list the website’s files. These
files include database files, HTML pages, ASP.NET pages, image
files, CSS files, configuration files, and so on. In addition to the
Solution Explorer, the right portion of the screen is also home to
the Database Explorer.
Creating a New ASP.NET Website
By default, the New Web Site dialog box should have Visual Basic as
the selected programming language, ASP.NET Web Site as the
selected website template, and the File System option selected in
the Web location drop-down list.
When you are creating a new website using the Empty Web Site
template, Visual Web Developer adds a single configuration file to
the project named web.config. Using other templates causes Visual
Web Developer to add many more files and folders to the new
website.
Creating a Simple ASP.NET
Page
ASP.NET Files
ASP.NET pages are broken into two files: one that contains the HTML
markup and Web control syntax, and another that contains the
source code. If you expand Default.aspx in the Solution Explorer,
you’ll see that there’s another file,Default.aspx.vb. This is the source
code file for Default.aspx.
HTML and Web Controls file
There are three “views” from which you can work with the HTML
elements and Web controls in an ASP.NET page. The first is the
Source view, which shows the page’s HTML markup and Web
control syntax. This is the default view and the one shown in
Figure 1.12. The second view, called the Design view, provides a
simpler alternative to specifying and viewing the page’s content.
In the Design view you can drag and drop HTML elements and
Web controls from the Toolbox onto the design surface. The third
view, Split, divides the screen in half, showing the Source view in
the top portion and the corresponding Design view in the bottom.
Testing the ASP.NET Page
From the Source view, place your cursor between the <div> and
</div> tags in Default.aspx and add the following text:
<h1>Hello, World!</h1>
Summary
Today, virtually all websites contain dynamic web pages of one kind
or another. Any website that allows a user to search its content,
order products, or customize the site’s content is dynamic in
nature.
Today, we took a look at the fundamental concepts of the .NET
framework. The .NET Framework is set of blueprints and objects.
Applications developed within this framework are compiled into
Microsoft Intermediate Language, and they produce meta-data that
describes them.
END