Velocity Reviews - Computer Hardware Reviews

Velocity Reviews > Newsgroups > Programming > ASP .Net > ASP General > Redirect After update help

Reply
Thread Tools

Redirect After update help

 
 
Mangler
Guest
Posts: n/a
 
      02-13-2007
I have a form that does multiple updates on the page. For some reason
that I cant figure out it is redirecting before the update is done.
It doesnt do this on another page that I have.

<%
If Request("Submit") <> "" Then
intRecIDs = Replace(Request("hidRecIDs"), "*", "") ' remove all the
asterisks, to create a list like this: 2, 5, 8, 9 etc.
arrRecIDs = Split(intRecIDs, ", ") ' Create an array, wich will
contain just the IDs of the records we need to update
For i = 0 to Ubound(arrRecIDs) ' Loop trough the array
strText = Replace(Request("qty" & arrRecIDs(i)), "'", "''")


set commUpdate = Server.CreateObject("ADODB.Command")
commUpdate.ActiveConnection = MM_connReclaim_STRING
commUpdate.CommandText = "UPDATE inventory SET qty = '" & strtext &
"' WHERE sku = '" &arrRecIDs(i) & "'"
commUpdate.CommandType = 1
commUpdate.CommandTimeout = 0
commUpdate.Prepared = true
commUpdate.Execute()
Next
strMessage = i & " Records Updated"
Response.Redirect("updateinventory?Message=" & strMessage)

End If

%>

Does anyone see why this may be happening?

 
Reply With Quote
 
 
 
Reply

Thread Tools

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
Update On The Windows Phone 7 Update Update Lawrence D'Oliveiro NZ Computing 2 02-25-2011 08:03 AM
Vista reactivation required after Microsoft Update optional update Colin Barnhorst Windows 64bit 32 05-26-2007 04:36 PM
Problem with Instiki update after OCI update Stephan Kämper Ruby 1 07-15-2006 01:41 PM
How to update datagrid after update =?Utf-8?B?TWljaGFlbA==?= ASP .Net 1 03-17-2006 07:24 PM
Basic Q - Response.Redirect, all redirect to first Response.Redirect statement Sal ASP .Net Web Controls 1 05-15-2004 03:46 PM



Advertisments