Web Forms is one of three programming patterns for creating ASP.NET websites and web applications.
The other two programming patterns are Web Pages and MVC (Model View Controller Model-View-Controller).
Web Forms is the oldest ASP.NET programming model and is an event-driven web page that integrates HTML, server controls, and server code.
Web Forms are compiled and executed on the server, and the server generates HTML to display as a web page.
Web Forms - Database Connection syntax
ADO.NET is also part of the .NET Framework. ADO.NET is used to handle data access. ADO.NET allows you to manipulate databases.
Web Forms - Database Connection example
<%@ Import Namespace="System.Data.OleDb" %> <script runat="server"> sub Page_Load dim dbconn dbconn=New OleDbConnection("Provider=Microsoft.Jet.OLEDB.4.0; data source=" & server.mappath("northwind.mdb")) dbconn.Open() end sub </script>