Managed Dbf

Click here to edit subtitle

;

- STDB Assembly


  Table.Navigator.IsBOF



- Command descriptions


Inquire if the record pointer is positioned at the beginning of a table.


Returns true if record's pointer is at the beginning of file marker, 

otherwise returns false,



- Parameters and overloads

     

  IsBOF( )



- Returns value


  Bool



- Example 
 
  // This example opens a customer database file, go to the last record and display customer's name on a message box
  //  move record pointer upward until beginning of file encountered close the table file and finally destroy customer object table.

  STDB.Table CUSTOMER = new STDB.Table();
  CUSTOMER.File.Use( @"\\MyServer\Data\FileMan\CUSTOMER.DBF", TableShare.Shared, TableAccess.ReadOnly, true );

  CUSTOMER.Navigator.GoBottom();
 
  while( ! CUSTOMER.Navigator.IsBOF() )
  { 
       var mRes = MessageBox.Show( "Customer :" + CUSTOMER.Reader.C("CUST_NAME") + " | Display next record?",
                                                       "SYSTEM ADVICE", MessageBoxButton.YesNo, MessageBoxImage.Question );

       if ( mRes == MessageBoxResult.No  )
       {
            break;
       }

       CUSTOMER.Navigator.Skip( -1 );
  }

  CUSTOMER.File.Use();
  CUSTOMER.Dispose(); CUSTOMER = null;


- Equivalent Visual FoxPro / Clipper / XBase codes

  USE \\MyServer\Data\FileMan\CUSTOMER.DBF  SHARED  NOUPDATE

  GO BOTTOM
 
  DO WHILE ! BOF()

        IF Messagebox( "Customer : "+CUSTOMER.cust_name+" | Dispplay next record?", 4+32 , "SYSTEM ADVICE" ) == 7
            EXIT
        ENDIF

        SKIP -1

 ENDDO

  USE
  CLOSE DATABASE



- Unhandle exception error
;