UtterAccess.com
X   Site Message
(Message will auto close in 2 seconds)

Welcome to UtterAccess! Please ( Login   or   Register )

Custom Search
 
   Reply to this topicStart new topic
> Error 3012 - No Records!, Access 2003    
 
   
zocker
post Feb 14 2020, 05:48 PM
Post#1


Utterly Eccentric and Moderator
Posts: 4,097
Joined: 4-March 00
From: Bristol / Ipswich / Spain/Gloucester


Greetings All!
My post HERE seems to have fallen off the radar! Maybe because I took too long to add the sample DB....if someone could have a look please! Its not critical but I don't like not knowing the answer..or indeed...the problem!

This is ancient Access 2003 but I think thats should not be of concern.

Thanks to all!

Zocker aka James Woodard

--------------------
I think they're for 1 am. Rene Descartes
Go to the top of the page
 
arnelgp
post Feb 15 2020, 12:56 AM
Post#2



Posts: 1,513
Joined: 2-April 09
From: somewhere out there...


you need to make sure there is a record on the recordset.
if it has record, make sure to move to the first record first:
CODE
With rs
    If Not (.BOF And .EOF) Then .MoveFirst
    

    While Not .EOF

        ' Add results to Result string

            Result = Result & "  " & !AccountID & ";  " & !AccName _
            & ";  " & !WhatFor & ";  " & !TransactionDate & ";"

           ' Debug.Print Result & vbCrLf

            rs.MoveNext

    Wend
End With


--------------------
Never stop learning, because life never stops teaching.
Go to the top of the page
 
zocker
post Feb 15 2020, 04:03 AM
Post#3


Utterly Eccentric and Moderator
Posts: 4,097
Joined: 4-March 00
From: Bristol / Ipswich / Spain/Gloucester


Thanks, I'll try that!

Z

--------------------
I think they're for 1 am. Rene Descartes
Go to the top of the page
 
cheekybuddha
post Feb 15 2020, 06:08 AM
Post#4


UtterAccess Moderator
Posts: 12,375
Joined: 6-December 03
From: Telegraph Hill


As mentioned in the other thread by DBG, I don't think that can be your issue, James. Your code already tests for .EOF before commencing the loop and it will be True if there are no records.

Did you see Bernie's response in the other thread - it seems he has narrowed down where your problem is arising.

--------------------


Regards,

David Marten
Go to the top of the page
 
zocker
post Feb 15 2020, 01:47 PM
Post#5


Utterly Eccentric and Moderator
Posts: 4,097
Joined: 4-March 00
From: Bristol / Ipswich / Spain/Gloucester


Thanks everyone!

Z

--------------------
I think they're for 1 am. Rene Descartes
Go to the top of the page
 


Custom Search


RSSSearch   Top   Lo-Fi    26th February 2020 - 03:14 PM