Professional Documents
Culture Documents
'For Access
strConnect = "Provider=Microsoft.Jet.OLEDB.4.0;" & "Data Source=" & Server.MapPath("sqlpractice.mdb") &
";Persist Security Info=False"
strCommand = "SELECT custname, custaddr, balance FROM customer"
objCommand.Fill(DataSet1)
DataGrid1.DataSource=DataSet1
DataGrid1.DataBind()
End Sub
</script>
<%
' importing namespaces (collection of objects) needed to work with data
%>
<%@ Import Namespace="System.Data" %>
<%@ Import Namespace="System.Data.OleDb" %>
<html>
<head>
<title>Data Grid Control example</title>
</head>
<body>
</body>
</html>
Formatting Examples:
OR
OR
OR