I have tried in vain after using 2 books - Wrox Prof ASP 3.0 and the compplete
Reference for DWMX and about 8 different tutorial sites on the web that
have examples on how to delete multiple records selected by checkbox. NONE
work. They wll work great until I put in the Command1.execute() line or the
rs_Raters_List_ID2.delete after gathering the data. I can write all the
variables out without those lines in and the values are correct and good
values which it should be able to delete, but to no avail.
This is the link for the page of records -
http://www.engconcepts.net/Verify_Ra...p?SupvID=10153
After selecting some and hitting Submit - it crashes. Below is the script
code before the HTML part of the page. This is just the last of many
unsuccessful approaches. I have taken this dysfunctional code out so you
can see the values that the checkbox selections bring over. I would love
some help here.
Thanks
George
<%
Dim rs_Raters_List
Dim rs_Raters_List_numRows
Set rs_Raters_List = Server.CreateObject("ADODB.Recordset")
rs_Raters_List.ActiveConnection = MM_websurveys_STRING
rs_Raters_List.Source = "SELECT ID, supervisor, rater, rater_email,
Rater_Code, Supv_Code FROM Non_Covered_Data WHERE rater='" +
Replace(rs_Raters_List__supervisor_code, "'", "''") + "' ORDER BY rater"
rs_Raters_List.CursorType = 0
rs_Raters_List.CursorLocation = 2
rs_Raters_List.LockType = 1
rs_Raters_List.Open()
rs_Raters_List_numRows = 0
%>
<%
Dim strDeleteChecked
strDeleteChecked = Request.Form("Raters")
Response.Write strDeleteChecked
%>
<%
Dim rs_Raters_List__ID2
rs_Raters_List__ID2 = "10001"
If (Request.Form("Supv_Code") <> "") Then
rs_Raters_List__ID2 = Request.Form("Supv_Code")
End If
%>
<%
strIDs = Replace(Request.Form, "&Raters=", ",")
strIDs = Replace(strIDs, "Raters", "")
arrIDs = Split(strIDs, ",")
%>
<%
For intCount = 0 To UBound(arrIDs)
rs_Raters_List.Filter = "ID = " & arrIDs(intCount)
rs_Raters_List.Delete
Next
rs_Raters_List.Close()
Response.Redirect("verify_raters.asp")
%>