Ask a Question related to ASP Database, Design and Development.
-
Nathan #1
Updating Access 2000 Records in .NET
Hi, I need some help. I have a on button click event that goes through a
survey and reads the items they choose and then updates the current record.
The problem I'm having is that nothing
actually is written back to the database even though it runs the command
even though an append query works just fine. any help would be appreciated.
<script runat="server">
Sub button_click(s as object, e as eventargs)
dim conUpdate as OleDBConnection
dim cmdUpdate as OleDBCommand
Dim strInput as String = Session( "UniqueID" )
Dim strSQL as String
conUpdate = New OleDbConnection ( "PROVIDER=Microsoft.Jet.OLEDB.4.0;DATA
SOURCE=d:\amcat\data\3001 eMortgage Survey.mdb" )
strSQL = "Update Campaign Set q1=@q1, q2=@q2, q3=@q3, q4=@q4, q5=@q5,
q6=@q6, q7=@q7, q8=@q8, q9=@q9, q10a=@q10, q10b=@q10b Where
uniquekey=@uniquekey"
cmdUpdate = New OleDBCommand( strSQL, conUpdate)
cmdUpdate.Parameters.Add( "@uniquekey", strInput )
'cmdUpdate.Parameters.Add( "@q1", aq1.Selectedvalue )
'cmdUpdate.Parameters.Add( "@q2", aq2.Selectedvalue )
cmdUpdate.Parameters.Add( "@q3", aq3.Selectedvalue )
cmdUpdate.Parameters.Add( "@q4", atxtq4.Text )
cmdUpdate.Parameters.Add( "@q5", aq5.Selectedvalue )
cmdUpdate.Parameters.Add( "@q6", aq6.Selectedvalue )
cmdUpdate.Parameters.Add( "@q7", aq7.Selectedvalue )
cmdUpdate.Parameters.Add( "@q8", aq8.Selectedvalue )
cmdUpdate.Parameters.Add( "@q9", aq9.Selectedvalue )
cmdUpdate.Parameters.Add( "@q10", aq10.Selectedvalue )
cmdUpdate.Parameters.Add( "@q10b", aq10b.Text )
lblAlert.Text = strSQL
conUpdate.Open()
cmdUpdate.ExecuteNonQuery()
conUpdate.Close()
End Select
End Sub
thanks
Nathan
Nathan Guest
-
Updating Records ( Dreamweaver MX 2004, ASP & Access )
hi there, I'm trying to update a record from a database but I don?t know how to do this from the new version because the behavior window it's... -
Updating Multi records
Is there any way to update muliple records in one database table in one go? -
Updating database records in a datagrid
In a datagrid, I read that you cannot add validation controls to the textboxes, you want to update, because they are using BoundColumns. I want to... -
Updating records when using a subform
On Wed, 23 Jul 2003 12:39:22 -0700, "JohnL" <johnlaidlaw@nospamtalk21.com> wrote: <ftp.ipswitch.com> -
Updating Multiple Records
I have a table in a database that contains all my photos. The fields are like Name, SRC, GalleryName, DateAdded, SpecialStyle. The only one you may... -
Bob Barrows #2
Re: Updating Access 2000 Records in .NET
This is a classic asp newsgroup. While you may be lucky enough to find a
dotnet-savvy person here who can answer your question, you can eliminate the
luck factor by posting your question to an appropriate group. I suggest
microsoft.public.dotnet.framework.adonet.
HTH,
Bob Barrows
Bob Barrows Guest
-
Nathan #3
Re: Updating Access 2000 Records in .NET
oops,
thanks
"Bob Barrows" <reb01501@NOyahoo.SPAMcom> wrote in message
news:#E13hITgDHA.3204@TK2MSFTNGP11.phx.gbl...the> This is a classic asp newsgroup. While you may be lucky enough to find a
> dotnet-savvy person here who can answer your question, you can eliminate> luck factor by posting your question to an appropriate group. I suggest
> microsoft.public.dotnet.framework.adonet.
>
> HTH,
> Bob Barrows
>
>
Nathan Guest



Reply With Quote

