Murach's ASP.NET 4 Web Programming
with VB 2010

How to use SQL data sources

This chapter shows you how to use the SqlDataSource control to access the data in a SQL Server database with little or no programming. Along the way, you'll learn how to use the DataList control to display lists of data in your ASP.NET applications.

Chapter 13 How to use SQL data sources
How to create a SQL data source 404
A Product List application that uses two SQL data sources 404
How to create a SqlDataSource control 406
How to define the connection 408
How to save the connection string in the web.config file 410
How to configure the Select statement 412
How to create a Where clause 414
How select parameters work 416
How to use custom statements and stored procedures 418
How to enter custom statements 418
How to select stored procedures 418
How to create a Select statement with the Query Builder 420
How to define the parameters 422
How to use the DataList control 424
How the DataList control works 424
How to define the templates for a data list 426
How to format a data list 428
How to use data binding 430
How to bind a list control to a data source 430
How to bind the controls in a template 432
The aspx file for the Product List application 434
How to use the advanced features of a SQL data source 436
How to create a data source that can update the database 436
How to change the data source mode 438
How to use caching 438




Murach's ASP.NET 4 with VB 2010

Learn more about this book

View the table of contents


More about the eBook



Our 100% Guarantee

First, try our books for 90 days. Then, if you aren't completely convinced that our books are the best ones you've ever used, you can return them for a prompt refund...no questions asked.