473,781 Members | 2,683 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

Either BOF or EOF is True, or the current Record has been deleted

19 New Member
I have error message when i run this script

QuerySelect = "SELECT a.DN, b.DIN, c.PIN, " & _
"c.UserName , b.Clock, d.ItemName " & _
"FROM ((ras_Device a INNER JOIN ras_AttRecord b ON a.DN=b.DN) " & _
"LEFT JOIN ras_Users c ON b.DIN=c.DIN) " & _
"LEFT JOIN ras_AttTypeItem d ON b.AttTypeId=d.I temId " & _
"WHERE b.DIN=c.DIN"
Set rsDataRAS = da_GetRs(QueryS elect)

QuerySelectSIKa wan = "SELECT * FROM " _
& "finger_data_ka ryawan"
Set rsSIKawan = da_GetRecord(Qu erySelectSIKawa n)

datetimeOut = rsSIKawan!TimeO ut >>> debug here
rsSIKawan.Close

rsSQL.CursorLoc ation = adUseClient

With rsSQL.Fields
.Append "idNo", adInteger
.Append "device", adInteger
.Append "idFinger", adInteger
.Append "nikKary", adVarChar, 50
.Append "namaKary", adVarChar, 100
.Append "time", adDate
.Append "tipeAbsen" , adVarChar, 64
End With

rsSQL.Open

If rsDataRAS.Recor dCount > 0 Then
jlhField = 0

While Not rsDataRAS.EOF Or rsDataRAS.BOF

rsSQL.AddNew
rsSQL("idNo").V alue = jlhField + 1
rsSQL("device") .Value = rsDataRAS("DN") .Value 'field device
rsSQL("idFinger ").Value = rsDataRAS("DIN" ).Value 'field finger ID
rsSQL("nikKary" ).Value = rsDataRAS("PIN" ).Value 'field nik karyawan
rsSQL("namaKary ").Value = rsDataRAS("User Name").Value 'field nama karyawan
rsSQL("time").V alue = rsDataRAS("Cloc k").Value 'field waktu
rsSQL("tipeAbse n").Value = rsDataRAS("Item Name").Value 'field tipe waktu

rsSQL.Update
rsDataRAS.MoveN ext
jlhField = jlhField + 1

If datetimeOut = "" _
Then
QueryUpdateSIKa wan = "UPDATE finger_data_kar yawan SET " _
& "TimeOut='" & Format(rsSQL("t ime").Value, "mm/dd/yyyy hh:nn:ss") & "'" _
& "WHERE Device='" & rsSQL("device") .Value & "' AND " _
& "idFinger=' " & rsSQL("idFInger ").Value & "' AND " _
& "NIKKary='" & rsSQL("nikKary" ).Value & "' AND " _
& "NamaKary=' " & rsSQL("namaKary ").Value & "' AND " _
& "TglHadir=' " & Format(rsSQL("t ime").Value, "mm/dd/yyyy") & "'" _
& "AND TimeIn='" & Format(rsSQL("t ime").Value, "" _
& "mm/dd/yyyy h:mm:ss") & "' AND TipeAbsen = " _
& "'" & rsSQL("idFInger ").Value & "'"
Call ExeQUERY(QueryU pdateSIKawan)
Else
QueryInsertSIKa wan = "INSERT INTO finger_data_kar yawan " _
& "(idNo, Device, idFinger, NIKKary, NamaKary, " _
& "TglHadir, TimeIn, TipeAbsen) " _
& "VALUES('" & rsSQL("idNo").V alue & "', '" & rsSQL("device") .Value & "', " _
& "'" & rsSQL("idFinger ").Value & "', '" & rsSQL("nikKary" ).Value & "', " _
& "'" & rsSQL("namaKary ").Value & "', " _
& "'" & Format(rsSQL("t ime").Value, "mm/dd/yyyy") & "', " _
& "'" & Format(rsSQL("t ime").Value, "mm/dd/yyyy h:mm:ss") & "', " _
& "'" & rsSQL("tipeAbse n").Value & "')"
Call ExeQUERY(QueryI nsertSIKawan)
End If

DoEvents
Wend

End If


Can anyone help me?

Regards,
Octo
Oct 7 '10 #1
1 2091
Stewart Ross
2,545 Recognized Expert Moderator Specialist
It suggests that your function da_GetRecord(Qu erySelectSIKawa n) is returning an empty recordset, in which case the error message is absolutely correct (as both EOF and BOF are true if there are no records in the recordset).

You don't show us da_GetRecord, so there is no more I can do at this stage to help. I'd suggest that you will need to set suitable breakpoints and walk through the function line by line to see why there are no records being returned.

-Stewart
Oct 9 '10 #2

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

Similar topics

3
7826
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.
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
16036
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
4637
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
1891
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
3510
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
1099
by: ramachandradurai | last post by:
hi, i am getting the error like.. Either EOF or BOF is true, or the current record has been deleted.Requested operation requires the current data. <%@ LANGUAGE="VBSCRIPT" %> <% 'PriceIt.asp (CV Pricing sheet). 'Project: WEPT
0
9474
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
10308
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
10143
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
8964
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing, and deployment—without human intervention. Imagine an AI that can take a project description, break it down, write the code, debug it, and then launch it, all on its own.... Now, this would greatly impact the work of software developers. The idea...
0
6729
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
5507
by: adsilva | last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
1
4040
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
3633
muto222
by: muto222 | last post by:
How can i add a mobile payment intergratation into php mysql website.
3
2870
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.