RecordCount only works if you are using a Static or KeySet cursor (maybe forwardonly also) since in most language I belive either forwardonly or keyset is automatically chosen as the default cursor, some of the cursors will return a negative one , for the recordcount if it doesnt support recordcount, such cursor is Dyanamic(typically any cursor that can receive update notification when the datasource is updated, cannot have a recordcount).