Get ready for BLACK FRIDAY shopping starting in

Forums

ASP

This topic is locked

multiple delete

Posted 03 Feb 2004 20:33:40
1
has voted
03 Feb 2004 20:33:40 barry gibson posted:
www.dmxzone.com/ShowDetail.asp?NewsId=3369
I have been following the example at the address above however i am struggling to get it to work here is the code i have

<pre id=code><font face=courier size=2 id=code>&lt;%
Dim rs_basket__MMColParam
rs_basket__MMColParam = "1"
If (Session("MM_Username" &lt;&gt; "" Then
rs_basket__MMColParam = Session("MM_Username"
End If
%&gt;
&lt;%
Dim rs_basket
Dim rs_basket_numRows

Set rs_basket = Server.CreateObject("ADODB.Recordset"
rs_basket.ActiveConnection = MM_conn_jubilee_STRING
rs_basket.Source = "SELECT * FROM tbl_windows WHERE belongsToUserID = '" + Replace(rs_basket__MMColParam, "'", "''" + "'"
rs_basket.CursorType = 0
rs_basket.CursorLocation = 2
rs_basket.LockType = 1
rs_basket.Open()

rs_basket_numRows = 0
%&gt;
&lt;%
strIDs = Replace(Request.Form, "&del=", ","
strIDs = Replace(strIDs, "del=", ""
arrIDs = Split(strIDs, ","
%&gt;
&lt;%
For intCount = 0 To UBound(arrIDs)
rs_basket.Filter = "windowID = " & arrIDs(intCount)
rs_basket.Delete
Next
rs_basket.Close()
Response.Redirect("infoSummary.asp"
%&gt; </font id=code></pre id=code>

however, i ma recieving this error msg when it is executed.

<pre id=code><font face=courier size=2 id=code> Error Type:
ADODB.Recordset (0x800A0CB3)
Object or provider is not capable of performing requested operation.
/jubilee/dodelete.asp, line 34</font id=code></pre id=code>

where line 34 is "rs_basket.Delete"
any help would be greatly appreciated. Thank you in advance - Barry

Replies

Replied 03 Feb 2004 21:07:42
03 Feb 2004 21:07:42 barry gibson replied:
using the sql the tutorial works but i am keen to try and get this method to work as it has advantages in diofferent situations, so your input is still needed please <img src=../images/dmxzone/forum/icon_smile.gif border=0 align=middle>

Reply to this topic