修复mdb提取遗漏问题

This commit is contained in:
Chenx221 2024-10-17 23:59:48 +08:00
parent 25c3ff879e
commit 96b93a722c
2 changed files with 8 additions and 2 deletions

View File

@ -95,9 +95,14 @@ namespace EscudeTools
sheet.col[i] = column; sheet.col[i] = column;
offset += 8; offset += 8;
} }
uint columnSizes = 0;
for(int i = 0; i < sheet.cols; i++)
{
columnSizes += sheet.col[i].size;
}
//process data //process data
offset = 0; offset = 0;
int recordNum = (int)(sheet_data.Length / (4 * sheet.cols)); int recordNum = (int)(sheet_data.Length / (columnSizes));//fix bug
Record recordFather = new(recordNum); Record recordFather = new(recordNum);
for (int i = 0; i < recordNum; i++) for (int i = 0; i < recordNum; i++)
{ {

View File

@ -114,7 +114,8 @@
// foreach (string file in files) // foreach (string file in files)
// { // {
// dm.LoadDatabase(file); // dm.LoadDatabase(file);
// if (dm.ExportDatabase(Path.GetDirectoryName(args[0])))
// Console.WriteLine("Export Database Success");
// } // }
//} //}