Wrox Programmer Forums
|
Classic ASP Databases Discuss using ASP 3 to work with data in databases, including ASP Database Setup issues from the old P2P forum on this specific subtopic. See also the book forum Beginning ASP.NET Databases for questions specific to that book. NOT for ASP.NET 1.0, 1.1, or 2.0.
Welcome to the p2p.wrox.com Forums.

You are currently viewing the Classic ASP Databases section of the Wrox Programmer to Programmer discussions. This is a community of software programmers and website developers including Wrox book authors and readers. New member registration was closed in 2019. New posts were shut off and the site was archived into this static format as of October 1, 2020. If you require technical support for a Wrox book please contact http://hub.wiley.com
 
Old March 20th, 2006, 08:42 PM
Authorized User
 
Join Date: Jan 2006
Posts: 20
Thanks: 0
Thanked 0 Times in 0 Posts
Default Operation not allowed in context+@@Identitty

Hello-

I have the following code: I get an error on the insert string that states Operation is not allowed in this context? Any ideas? Could it be the @@identity or the nextrecordset call?

Code:
elseif Request.Form("new") <> "" then
set rcs = GetFromDatabase("insert tblSR(srPublication, srClassification, srCaption, srText, srAgentID, srOfficeId, srDateTime, srMLS, srListingID) values('" & srPublication & "','" & srClassification & "','" & srCaption & "','" & srText & "','" & srAgentID & "','" & srOfficeID & "','" & srDateTime & "','" & srMLS & "','" & srListingID & "')SELECT @@IDENTITY").nextrecordset
newsrID = rcs(0)
    if Date1 <> "" then
    GetFromDatabase "insert tblSRPub(srID, PubDate, PubAgent, PubPhone, MLS, ListID, OHTime) values('" & newsrID & "','" & Date1 & "','" & AgentName1 & "','" & AgentPhone1 & "','" & srMLS & "','" & srListingID & "','" & OHTime1 & "')"
    end if
    if Date2 <> "" then
    GetFromDatabase "insert tblSRPub(srID, PubDate, PubAgent, PubPhone, MLS, ListID, OHTime) values('" & newsrID & "','" & Date2 & "','" & AgentName2 & "','" & AgentPhone2 & "','" & srMLS & "','" & srListingID & "','" & OHTime2 & "')"
    end if
    if Date3 <> "" then
    GetFromDatabase "insert tblSRPub(srID, PubDate, PubAgent, PubPhone, MLS, ListID, OHTime) values('" & newsrID & "','" & Date3 & "','" & AgentName3 & "','" & AgentPhone3 & "','" & srMLS & "','" & srListingID & "','" & OHTime3 & "')"
    end if
response.write "<script>window.close();</script>"
response.end
end if





Similar Threads
Thread Thread Starter Forum Replies Last Post
Operation is not allowed when obejct is closed zazo XSLT 19 July 25th, 2008 01:26 PM
Operation is not allowed when the object is closed kingroon Classic ASP Databases 2 February 5th, 2008 10:29 AM
operation is not allowed when the object is opened naveed77 Beginning VB 6 4 August 2nd, 2006 09:09 PM
Operation is not allowed when object is opened. dpkbahuguna Beginning VB 6 2 April 3rd, 2006 10:53 PM
3219 Error: Operation Not Allowed in this Context dolfandave VB Databases Basics 0 May 17th, 2005 10:09 AM





Powered by vBulletin®
Copyright ©2000 - 2020, Jelsoft Enterprises Ltd.
Copyright (c) 2020 John Wiley & Sons, Inc.