Guys,
This piece of code to insert a new student into the DB was working perfectly, i dont know hwat i did to screw it up but maybe the error is blatantly obvious to someone more experienced.
<%@ Page Language="VB" Debug="True" %>
<%@ import Namespace="System.Data" %>
<%@ import Namespace="System.Data.OleDb" %>
<script runat="server">
Sub btnInsertClick(Sender As Object, E As EventArgs)
Dim aConnection As OleDbConnection = New OleDbConnection
Dim aConnectionString As String
Dim aQuery As String
aConnectionString = "Provider=Microsoft.Jet.OLEDB.4.0; Data Source=C:\Inetpub\wwwroot\records.mdb"
aConnection.ConnectionString = aConnectionString
Dim aCommand As OleDbCommand = New OleDbCommand
aConnection.Open()
aQuery = "Insert Into Students(StudentID, FirstName, LastName, EmailName, BirthDate, Pword) VALUES ('"& StudID.Text &"', '"& F_Name.Text &"', '"& L_Name.Text &"', '"& Email.Text &"', '"& D_O_B.Text &"', '"& Pword1.Text &"')"
aCommand.Connection = aConnection
aCommand = New OleDbCommand(aQuery, aConnection)
End Sub
</script>
<html>
<head>
</head>
<body background="./images/graduate.gif">
<form runat="server">
<div align="center">
<table width="607" align="center" border="0">
<tbody>
<tr>
<td colspan="3" height="201">
<img height="91" src="images/crest.gif" width="574" align="top" border="3" />
<table cellspacing="0" cellpadding="0" width="100%" border="0">
<tbody>
<tr>
<td height="80">
<h2 align="center"><font face="geneva,arial" size=+3><b>Registration Information </b></font>
</h2>
<font face="geneva,arial" size="-1"> </font></td>
</tr>
</tbody>
</table>
</td>
</tr>
<tr>
<td align="right" width="198">
<font face="Arial" size="2">First Name: </font></td>
<td width="399">
<asp:TextBox id="F_Name" runat="server" width="200px" maxlength="25"></asp:TextBox>
<asp:RequiredFieldValidator id="FNameReq" runat="server" ErrorMessage="* You Must Enter a First name" ControlToValidate="F_Name"></asp:RequiredFieldValidato r>
</td>
</tr>
<tr>
<td align="right">
<font face="Arial" size="2">Last Name:</font>
</td&g