J
Jack
hI,
Anyone here know how to connect asp.net with MS-access and also how to pass
data to a table?
The following is the code which I have but unfortunately its not working..
Public Connectionstring As String =
"Provider=Microsoft.Jet.OLEDB.4.0;Data Source =
C:\Inetpub\wwwroot\Dee\ASPdotnet\currt.mdb;Persist Security Info=False;"
Public con As New OleDbConnection(Connectionstring)
Dim strSelect As String
strSelect = "Insert Into UserDetails1 (Username) Values
(@DetailsUser)"
Dim cmd As New OleDbCommand(strSelect, con)
Dim added As Integer
cmd.Parameters.Add("@DetailsUser", txtUserDetails.Text)
Try
con.Open()
cmd.ExecuteNonQuery()
Response.Write("Updated Successfully!<p> </p><p> </p><p> </p>")
con.Close()
Response.Write("Updated Successfully!<p> </p><p> </p><p> </p>")
Catch
con.Close()
End Try
Thanks in advance
Jack
Anyone here know how to connect asp.net with MS-access and also how to pass
data to a table?
The following is the code which I have but unfortunately its not working..
Public Connectionstring As String =
"Provider=Microsoft.Jet.OLEDB.4.0;Data Source =
C:\Inetpub\wwwroot\Dee\ASPdotnet\currt.mdb;Persist Security Info=False;"
Public con As New OleDbConnection(Connectionstring)
Dim strSelect As String
strSelect = "Insert Into UserDetails1 (Username) Values
(@DetailsUser)"
Dim cmd As New OleDbCommand(strSelect, con)
Dim added As Integer
cmd.Parameters.Add("@DetailsUser", txtUserDetails.Text)
Try
con.Open()
cmd.ExecuteNonQuery()
Response.Write("Updated Successfully!<p> </p><p> </p><p> </p>")
con.Close()
Response.Write("Updated Successfully!<p> </p><p> </p><p> </p>")
Catch
con.Close()
End Try
Thanks in advance
Jack