func prepareNewTable(_ fileType: Int) -> Bool

Function prepareNewTable() prepares internal structures for creating a new table.
The simple version of this function accepts a file type, and the extended version allows you to define size of memo fields and provide a name of driver (for dbaseLevel7 only).

func prepareNewTable(_ fileType: Int, memoSize: Int, driver: String?) -> Bool


// if dbf.prepareNewTable(2, memoSize:512, driver:nil)
if dbf.prepareNewTable(0)
{
    dbf.addField("ID", fieldType:'N', length:10);
    dbf.addField("NAME", fieldType:'C', length:20);
    dbf.addField("BIRTH", fieldType:'D', length:8);
    dbf.addField("WEIGHT", fieldType:'N', length:10, decimal:2);

    // if dbf.createAndOpenTable("testfile.dbf") {
    if dbf.createTable("testfile.dbf") {
        print("OK");
    } else {
        print("Error");
    }
}