Hi all
Another question
How can I trap for an error from the execute method? See below. I tried "If Err", but it didnt work.
Also, can I encase multiple execute methods into a begintrans?
Thanks
![[spin] [spin] [spin]](/data/assets/smilies/spin.gif)
![[spin] [spin] [spin]](/data/assets/smilies/spin.gif)
Check if a user was selected and if delete was pressed
' If so, delete the appropriate user
if isnumeric(request.form("userlist"
not isempty(request.form("delete)) then
connectionstring = "DSN=sql-db;UID=;PWD="
set sqldb = Server.CreateObject("ADODB.Connection"
sqldb.CommandTimeout = 1000
sqldb.open ConnectionString
cSql = _
"DELETE FROM iuser WHERE userid=" & _
rtrim(request.form("userlist1"
sqldb.Execute (cSql)
end if