473,791 Members | 2,985 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

Either EOF or BOF is true, or the current record has been deleted.

1 New Member
hi, i am getting the error like..


Either EOF or BOF is true, or the current record has been deleted.Request ed operation requires the current data.



<%@ LANGUAGE="VBSCR IPT" %>
<% 'PriceIt.asp (CV Pricing sheet).
'Project: WEPT
'Created: 6/11/00
'Author: CIH

Option Explicit
Response.AddHea der "Pragma", "No-cache"
Response.Expire s = 0
Response.CacheC ontrol = "no-cache"

If Trim(Request.Co okies("modyr")) ="" Then
Response.Redire ct "../MMMYmenu.asp?UR L=CVPricing/PBatchMenu.asp& LevReqd=MMMY"
End If

Server.ScriptTi meout=3600
Response.Buffer = True
%>

<!-- #INCLUDE FILE = "../CSLincludes.asp " -->

<%
Dim strForm
Dim strHidden
Dim strOutput
Dim objHdrInfo
Dim rstHdrInfo
Dim strHdrInfo
Dim strError
Dim objCVP
Dim rstBatchHdr
Dim rstEntities
Dim intCounter
Dim strVATRate
Dim rstFeatures
Dim sMarket
Dim sModelLine
Dim sModelYear
Dim objAdmin
Dim rstCurrencies
Dim strBatchHdr
Dim strCur
Dim strDesc
Dim strEffDate
Dim strID

strHidden = ""
strForm = ""

'Get header info
sMarket = Request.Cookies ( "mkt" )
sModelLine = Request.Cookies ( "modln" )
sModelYear = Request.Cookies ( "modyr" )
Set objAdmin = Server.CreateOb ject("WEPT_DotN et.clsAdmin")
Call objAdmin.GetHdr Info( CStr( Request.Cookies ( "user" ) ), sMarket, CStr( Request.Cookies ( "lang" ) ), sModelLine, sModelYear )
Set objAdmin = Nothing

If Len( sMarket ) = 0 Or Err.number <> 0 Then
strHdrInfo = "<No description available>"
Else
strHdrInfo = sMarket & " " & sModelLine & " " & sModelYear
End If

'Get batch header
If strError = "" Then
If Request.QuerySt ring("pBatch")= "-1" Then
strBatchHdr = "New Batch" & vbCRLF
Else
Set objCVP = Server.CreateOb ject("WEPT_DotN et.clsCVPricing ")
If Err <> 0 Then
strError = "Error creating WEPT object:" & Err.Number & " " & Err.Description
Else
Set rstBatchHdr = objCVP.GetBatch Hdr(Request.Coo kies("user"),Re quest.Cookies(" mktISO"), _
Request.QuerySt ring("pbatch"), _
Request.QuerySt ring("source"), _
strError)
End If
If strError = "" Then
If rstBatchHdr.EOF Then
strBatchHdr = "<No info available>"
strCur = ""
strDesc = ""
strEffDate = ""
strError = "No data was found for the batch header."
Else
strBatchHdr = Request.QuerySt ring("pbatch") & ": " & rstBatchHdr("De sc")
strCur = rstBatchHdr("Cu r")
strDesc = rstBatchHdr("De sc")
strEffDate = rstBatchHdr("Ef fDate")
End If
rstBatchHdr.Clo se
End If
End If
End If
Set rstBatchHdr = Nothing

If strError = "" Then
strHidden = strHidden & _
"<INPUT TYPE='HIDDEN' NAME=txtSrc VALUE='" & Request.QuerySt ring("source") & "'>" & vbCRLF & _
"<INPUT TYPE='HIDDEN' NAME=txtpBatch VALUE='" & Request.QuerySt ring("pBatch") & "'>" & vbCRLF
strForm = "<TABLE>" & "<TR>"
Set objAdmin = Server.CreateOb ject("WEPT_DotN et.clsAdmin")
Set rstCurrencies = objAdmin.GetCur rencies(Request .Cookies("user" ),Request.Cooki es("mktISO"), strError)
If strError <> "" Then
strForm = strForm & "<TD>Curren cy Code: " & _
"<INPUT TYPE=TEXT SIZE=10 MAXLENGTH=8 NAME=txtCurrenc y VALUE='" & strCur & "'></TD" & vbCRLF
Else
strForm = strForm & "<TD>Curren cy: <SELECT NAME=txtCurrenc y>"
Do While Not rstCurrencies.E OF
If rstCurrencies(" Code") = strCur Then
strForm = strForm & "<OPTION VALUE='" & rstCurrencies(" Code") & "' SELECTED>" & rstCurrencies(" Description") & "</OPTION>" & vbCRLF
Else
strForm = strForm & "<OPTION VALUE='" & rstCurrencies(" Code") & "'>" & rstCurrencies(" Description") & "</OPTION>" & vbCRLF
End If
rstCurrencies.M oveNext
Loop
rstCurrencies.C lose
Set rstCurrencies = Nothing
strForm = strForm & "</SELECT></TD>" & vbCRLF
End If
strForm = strForm & "<TD>Descriptio n: " & _
"<INPUT TYPE='TEXT' SIZE=20 NAME=txtDesc VALUE=""" & strDesc & """></TD>" & vbCRLF & _
"<TD>Effect ive Date: " & _
"<INPUT TYPE='TEXT' SIZE=10 NAME=txtEffDate VALUE=""" & strEffDate & """>(YYYYMM DD)</TD>" & vbCRLF & _
"<TD>VAT Rate: " & _
"<INPUT TYPE='TEXT' SIZE=5 NAME=txtMstrVAT VALUE=0></TD>" & vbCRLF & _
"</TR>" & vbCRLF & _
"</TABLE>" & vbCRLF & _
"<BR>" & vbCRLF
Set objAdmin = Nothing
End If

'Begin Entity pricing
If strError = "" Then
Set objCVP = Server.CreateOb ject("WEPT_DotN et.clsCVPricing ")
Set rstEntities = objCVP.GetEntPr icing(Request.C ookies("user"), Request.Cookies ("mktISO"), _
Request.Cookies ("lang"), _
Request.Cookies ("modln"), _
Request.QuerySt ring("pbatch"), _
Request.QuerySt ring("source"), _
strError)
End If

If strError = "" Then
strForm = strForm & "<H2><CENTER>En tity Pricing</CENTER></H2>" & vbCRLF
If Not rstEntities.BOF Then
strForm = strForm & "<TABLE BORDER VALIGN=CENTER CELLPADDING=1>< TR>" & vbCRLF
strForm = strForm & "<TD BGCOLOR=#909090 ><FONT COLOR=#ffffff>B odystyle</TD>" & vbCRLF
strForm = strForm & "<TD BGCOLOR=#909090 ><FONT COLOR=#ffffff>D erivative</TD>" & vbCRLF
strForm = strForm & "<TD BGCOLOR=#909090 ><FONT COLOR=#ffffff>E ngine</TD>" & vbCRLF
strForm = strForm & "<TD BGCOLOR=#909090 ><FONT COLOR=#ffffff>T ransmission</TD>" & vbCRLF
strForm = strForm & "<TD BGCOLOR=#909090 ><FONT COLOR=#ffffff>A xle</TD>" & vbCRLF
strForm = strForm & "<TD BGCOLOR=#909090 ><FONT COLOR=#ffffff>N et</TD>" & vbCRLF
strForm = strForm & "</TR>" & vbCRLF
intCounter = 0
Do While Not rstEntities.EOF
'Keep the connection alive
'Response.Write "<!-- dummy -->"
'Response.Flush
strID = CStr(intCounter )
strHidden=strHi dden & "<INPUT TYPE='HIDDEN' NAME=EECd" & strID & " VALUE='" & rstEntities("En tCode") & "'>" & vbCRLF
strForm = strForm & "<TR>" & vbCRLF & _
"<TD>" & FormatTD(rstEnt ities("Bodystyl e"), rstEntities("Bo dyCode")) & "</TD>" & _
"<TD>" & FormatTD(rstEnt ities("Derivati ve"), rstEntities("De rivCode")) & "</TD>" & _
"<TD>" & FormatTD(rstEnt ities("Engine") , rstEntities("En gCode")) & "</TD>" & _
"<TD>" & FormatTD(rstEnt ities("Transmis sion"), rstEntities("Tr ansCode")) & "</TD>" & _
"<TD>" & FormatTD(rstEnt ities("Axle"), rstEntities("Ax leCode")) & "</TD>"
If IsNull(rstEntit ies("Net")) Then strOutput = "" Else strOutput = CStr(rstEntitie s("Net"))
strForm = strForm & "<TD><INPUT TYPE='TEXT' SIZE=10 NAME=ENet" & strID & " VALUE='" & strOutput & "'></TD>" & vbCRLF
strForm = strForm & "</TR>" & vbCRLF
If rstEntities("VA T") <> "" And strVATRate = "" Then strVATRate = rstEntities("VA T")
rstEntities.Mov eNext
intCounter=intC ounter+1
Loop
strHidden=strHi dden & "<INPUT TYPE='HIDDEN' NAME=txtEntRowC ount VALUE='" & intCounter-1 & "'>" & vbCRLF
rstEntities.Clo se
Set rstEntities = Nothing
strForm = strForm & "</TABLE>" & vbCRLF
End If

End If

'Begin Feature Pricing
If strError = "" Then
Set objCVP = Server.CreateOb ject("WEPT_DotN et.clsCVPricing ")
Set rstFeatures = objCVP.GetFeatP ricing(Request. Cookies("user") ,Request.Cookie s("mktISO"), _
Request.Cookies ("lang"), _
Request.Cookies ("modln"), _
Request.QuerySt ring("pbatch"), _
Request.QuerySt ring("source"), _
strError)
End If

If strError = "" Then
strForm = strForm & "<H2><CENTER>Fe ature Pricing</CENTER></H2>" & vbCRLF
If Not rstFeatures.BOF Then
strForm = strForm & "<TABLE BORDER VALIGN=CENTER CELLPADDING=1>< TR>" & vbCRLF
strForm = strForm & "<TD BGCOLOR=#909090 ><FONT COLOR=#ffffff>D el?</TD>" & vbCRLF
strForm = strForm & "<TD BGCOLOR=#909090 ><FONT COLOR=#ffffff>B odystyle</TD>" & vbCRLF
strForm = strForm & "<TD BGCOLOR=#909090 ><FONT COLOR=#ffffff>F eature</TD>" & vbCRLF
strForm = strForm & "<TD BGCOLOR=#909090 ><FONT COLOR=#ffffff>N et</TD>" & vbCRLF
strForm = strForm & "</TR>" & vbCRLF
intCounter = 0
Do While Not rstFeatures.EOF
'Keep the connection alive
'Response.Write "<!-- dummy -->"
'Response.Flush
strID = CStr(intCounter )
strHidden=strHi dden & "<INPUT TYPE='HIDDEN' NAME=OBCd" & strID & " VALUE='" & rstFeatures("Bo dyCode") & "'>" & vbCRLF
strHidden=strHi dden & "<INPUT TYPE='HIDDEN' NAME=OFCd" & strID & " VALUE='" & rstFeatures("Fe atCode") & "'>" & vbCRLF
strForm = strForm & "<TR>" & vbCRLF & _
"<TD><INPUT TYPE=CHECKBOX NAME=ODel" & strID & " VALUE='Del'></TD>" & _
"<TD>" & FormatTD(rstFea tures("Bodystyl e"), rstFeatures("Bo dyCode")) & "</TD>" & _
"<TD>" & rstFeatures("Fe atCode") & ": " & FormatTD(rstFea tures("Feature" ), "No description") & "</TD>"
If IsNull(rstFeatu res("Net")) Then strOutput = "" Else strOutput = CStr(rstFeature s("Net"))
strForm = strForm & "<TD><INPUT TYPE='TEXT' SIZE=10 NAME=ONet" & strID & " VALUE='" & strOutput & "'></TD>" & vbCRLF
strForm = strForm & "</TR>" & vbCRLF
rstFeatures.Mov eNext
intCounter=intC ounter+1
Loop
strHidden=strHi dden & "<INPUT TYPE='HIDDEN' NAME=txtFeatRow Count VALUE='" & intCounter-1 & "'>" & vbCRLF
rstFeatures.Clo se
Set rstFeatures = Nothing
strForm = strForm & "</TABLE>" & vbCRLF
strForm = strForm & "<BR><BR><I NPUT TYPE=BUTTON NAME=BtnSubmit VALUE='Save' onClick=""Submi tForm('Normal') ;"">" & vbCRLF
strForm = strForm & "<INPUT TYPE=button NAME=BtnCancel VALUE='Cancel' onClick='BtnCan cel_OnClick();' >" & vbCRLF
End If

End If
Sep 21 '10 #1
0 1099

Sign in to post your reply or Sign up for a free account.

Similar topics

3
7828
by: Maria | last post by:
Is there another way to delete the current record in a subform from the main form, another subform or a sub-subform other than setting focus on a field in the subform and using run command acCmdDelete Record? Thanks! Maria
3
1548
by: Prakash | last post by:
Below is my code to delete a record in a continuous form. I can't figure out any reason but sometimes (another) record gets deleted instead of where the record pointer is positioned. Small table - just 750 records ... no primary key defined. Using Access 2003 under WinXP SP1. There must be something I've overlooked. Maybe one of you gurus could help.
3
26287
by: hebandgene | last post by:
When I delete a record in a subform I get the warning that I'm about to delete a record, followed by an error "No current record." When I click OK obviously the record is deleted and it goes to the first record (as I've coded it to do) or it shows me a blank record if the deleted record was the only one. So, what I'd like to do is bypass that 'No current record' altogether to avoid user confusion. Is there any way to code it out...
6
4305
by: jpatchak | last post by:
Hello, I have a main form with one subform. I have a command button on the main form to delete the current record. Below is my code. The tables on which the main form and subform are based cascade deletions and updates, so getting rid of the record in the table for the main form should delete any corresponding records in the table for the subform. Everything appears to be working correctly in this code from the standpoint of the tables. ...
3
16037
by: Kosmos | last post by:
Hey ya'll...I can't seem to figure out why I'm getting this error message, but it all started when I added the new line of code with the recSet5.AddNew --- when I ran the first line, the logic worked and the fields were populated properly, when I added all the rest, it wouldn't run and even when I tried to go back, it still won't run now...I am getting the following error message: "Either BOF or EOF is True, or the current record has been...
3
4638
by: marcf | last post by:
Hi Everyone, Hopefully someone will be able to offer a suggestion to this problem. I have a multi user CMS running at work which I wrote. Aside from a few bugs everything has been going fine except for one annoying problem. Heres the info: Windows XP workstations connecting to a windows 2003 server with roaming profiles for each user. Access 2003 SP2 on all machines. Error: Record is deleted 3167
1
1893
by: THEAF | last post by:
i'm trying to create a reminder form, when i add a new reminder its ok but when i try to delete a reminder then i get No Current Record problem. Form Load Private Sub Form_Load() Dim s() As String Dim ListTime As String Dim ListDate As String Dim i As Integer Set dbReminder = OpenDatabase(App.Path & "\Password.mdb") Set rsReminder = dbReminder.OpenRecordset("Reminder", dbOpenDynaset)
5
5326
by: TimSki | last post by:
Hi, This is very strange... I have a simple query using a recordset thus... set rsID = CreateObject("ADODB.recordset") searchPhrase = "SELECT blah...." rsID.Open searchPhrase, oConn
1
3030
vikas251074
by: vikas251074 | last post by:
Hello sir, I am facing some problem for which I am trying hard to solve it. But in vain. This programe is for View/Deletion. When I run program for first time, I select vlan from list and press Enter key, it display the details. Now when I again select vlan from list and press Enter key, following error occurs. Error Type: ADODB.Field (0x80020009) Either BOF or EOF is True, or the current record has been deleted. Requested operation...
4
3511
by: jbrumbau | last post by:
Hello, I have a function that goes through each field in a form and checks if it was changed between itself and the existing recordset. It is used to track changes done in any record when the logged in user (Forms!frmLogin!cboUname.Column(4)) is logged in. The problem I have is when my control loop checks a field that is linked to a table with a deleted record, the function crashes. This situation arises when two forms are opened at the...
0
9515
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can effortlessly switch the default language on Windows 10 without reinstalling. I'll walk you through it. First, let's disable language synchronization. With a Microsoft account, language settings sync across devices. To prevent any complications,...
0
10427
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers, it seems that the internal comparison operator "<=>" tries to promote arguments from unsigned to signed. This is as boiled down as I can make it. Here is my compilation command: g++-12 -std=c++20 -Wnarrowing bit_field.cpp Here is the code in...
0
10207
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven tapestry of website design and digital marketing. It's not merely about having a website; it's about crafting an immersive digital experience that captivates audiences and drives business growth. The Art of Business Website Design Your website is...
0
9995
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each protocol has its own unique characteristics and advantages, but as a user who is planning to build a smart home system, I am a bit confused by the choice of these technologies. I'm particularly interested in Zigbee because I've heard it does some...
0
6776
by: conductexam | last post by:
I have .net C# application in which I am extracting data from word file and save it in database particularly. To store word all data as it is I am converting the whole word file firstly in HTML and then checking html paragraph one by one. At the time of converting from word file to html my equations which are in the word document file was convert into image. Globals.ThisAddIn.Application.ActiveDocument.Select();...
0
5559
by: adsilva | last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
1
4110
by: 6302768590 | last post by:
Hai team i want code for transfer the data from one system to another through IP address by using C# our system has to for every 5mins then we have to update the data what the data is updated we have to send another system
2
3718
muto222
by: muto222 | last post by:
How can i add a mobile payment intergratation into php mysql website.
3
2916
bsmnconsultancy
by: bsmnconsultancy | last post by:
In today's digital era, a well-designed website is crucial for businesses looking to succeed. Whether you're a small business owner or a large corporation in Toronto, having a strong online presence can significantly impact your brand's success. BSMN Consultancy, a leader in Website Development in Toronto offers valuable insights into creating effective websites that not only look great but also perform exceptionally well. In this comprehensive...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.