Student_del.asp
This script displays nothing.
Script listing
Delete record
<%
' This script deletes record rID after the user confirms the action.
Dim rID ' the record ID of the record to be deleted
rID = Request.QueryString("RecID")
Dim DataConn
' Create and establish data connection
Set DataConn = Server.CreateObject("ADODB.Connection")
DataConn.Mode = 3 '3 = adModeReadWrite
DataConn.ConnectionTimeout = 5
DataConn.CommandTimeout = 12
DataConn.Open Session.Value("DBOpen")
' Create and link command object to data connection then set attributes and SQL query
Dim cmdDel
cmdDel = "DELETE FROM Roster_CIS" & " WHERE RecID = " & rID
DataConn.Execute cmdDel
' return connection memory
DataConn.Close
Set DataConn = Nothing
Response.Redirect("roster_view.asp") ' transition to roster_view
%>