Welcome to the new platform of Programmers Heaven! We apologize for the inconvenience caused, if you visited us from a broken link of the previous version. The main reason to move to a new platform is to provide more effective and collaborative experience to you all. Please feel free to experience the new platform and use it's exciting features. Contact us for any issue that you need to get clarified. We are more than happy to help you.
MS Access EOF and BOF property problems please help
I don't seem to be able to get MS Access to return the BOF and EOF property of the RecordSet rsDB
I whant to check of the Returned recordset is Empty with EOF and BOF is True but somehow it keeps giving the value False
even when in the SQL statement the result is no records found.
Why will access not return the expected EOF and BOF status ?? ( I expected both to be True
I temporarily changed it to check for IsNull but I whanted to use BOF and EOF there
Can any one help me ??
Dim cnnDB As ADODB.Connection
Set cnnDB = CurrentProject.Connection
Dim rsDB As ADODB.Recordset
Set rsDB = New ADODB.Recordset
rsDB.Open "SELECT Min(AccntPeriods.AccPerID) AS CurrAccPerID FROM AccntPeriods WHERE ((AccntPeriods.Status)=""O"");", cnnDB
If IsNull(rsDB("CurrAccPerID")) Then
Form_Main.lblCBPeriod.Caption = "Error"
Form_Main.lblCBPeriod.Caption = (rsDB("CurrAccPerID"))