#1
  1. No Profile Picture
    Registered User
    Devshed Newbie (0 - 499 posts)

    Join Date
    Jul 2012
    Posts
    28
    Rep Power
    0

    Error : Either EOF or BOF is true


    I'm receiving this error, while i tried to assign
    TDataSet.RecNo := TDataSet1.RecNo

    While executing,
    current record value of TDataSet is -1
    current record value of TDataSet1 is 2

    Thanks in advance..
  2. #2
  3. No Profile Picture
    Contributing User
    Devshed Regular (2000 - 2499 posts)

    Join Date
    Jan 2006
    Location
    Carlsbad, CA
    Posts
    2,057
    Rep Power
    383
    Hard to understand the relationship between Title and message body.
    Is RecNo a field in your table or a property of TDataset ( not currently at my PC)?
    Is TDataset on an existing record?
    Is TDataset in edit mode?
  4. #3
  5. No Profile Picture
    Registered User
    Devshed Newbie (0 - 499 posts)

    Join Date
    Jul 2012
    Posts
    28
    Rep Power
    0
    Originally Posted by clivew
    Hard to understand the relationship between Title and message body.
    Is RecNo a field in your table or a property of TDataset ( not currently at my PC)?
    Is TDataset on an existing record?
    Is TDataset in edit mode?

    Hi clivew, When i tried to trace the source of the ' Either EOF or BOF is true' error message.
    It leads to the line,
    TDataSet.RecNo := TDataSet1.RecNo

    1.RecNo is the property
    2.No, TDataSet is a dummy dataset (Empty)

    Here i tried to fetch the recno(Property) of the active dataset(Tdataset1) and pass it to dummy dataset(Tdataset).
    Finally perform the deletion on both the dataset.
  6. #4
  7. No Profile Picture
    Contributing User
    Devshed Regular (2000 - 2499 posts)

    Join Date
    Jan 2006
    Location
    Carlsbad, CA
    Posts
    2,057
    Rep Power
    383
    RecNo is not a property that you can pass around.
    If implemented, it usually represents the order in which a record was fetched from a query?
    i.e. Third record fetched from SQL query will have RecNo = 3. Not something you can assign.
    Also if TDataset is empty that would explain your error message.
    Before you even get to the RecNo value I presume the error message is generated by the fact that there is no active record in TDataset to which a RecNo value could be assigned anyway.
    Finally FYI: The RecNo property is not implemented in TDataset. It always returns -1.
    Descendants implement it as appropriate.

    HTH

    Clive

IMN logo majestic logo threadwatch logo seochat tools logo