iam uploading and excel file with .csv format using an class which having code below to upload:
Actual error msg is : Number of errors found is >10000
i should get the msg this info(strfmt('%1(ILFS), %2(IFIN) ,%3(IIML) records are uploaded in %4 table.',j,k,l,tableName)); but not geeting
void uploadMFMaster()
{
#AviFiles
ITL_COC_MFTable _COC_MFTable;
Filename filename1;
FilePath filePath;
filenameType filenameType;
str sheetName;
str strSQL;
str filepathstr;
real a;
;
sysOperationProgress = new SysOperationProgress(1);
tableName = "COC Mutual Fund Master";
i = 2;
j = 0;
k = 0;
l = 0;
setPrefix("@SYS54767");
sysOperationProgress.setAnimation(#AviFileMove);
sysOperationProgress.setCaption("@SYS54767");
[filePath, filename1, filenameType] = fileNameSplit(filename);
if(filenameType!='.xls')
throw error('File should be in xls format');
app = SysExcelApplication::construct();
Workbooks = app.Workbooks();
COMVariant1 = new COMVariant();
WinAPI::fileExists(fileName);
COMVariant1.bStr(fileName);
Workbook = Workbooks.Add(COMVariant1);
Worksheets = Workbook.worksheets();
Worksheet = Worksheets.itemFromNum(1);
Cells = Worksheet.Cells();
firstRow = this.findFirstRow();
lastRow = this.findLastRow();
rows = lastRow;
sysOperationProgress.setTotal(rows);
ttsbegin;
while(i <=rows)
{
// Modified on 05 Aug 2010 at 11:53:14 by Hemant
/*insertion of record into current company*/
this.uploadrecords();
/*insertion of record into current company ends*/
/*insertion of same record into other company*/
if(curext() == "ILF")
{
changecompany("IFN")
this.uploadrecords();
changecompany("IIM")
this.uploadrecords();
}
if(curext() == "IFN")
{
changecompany("ILF")
this.uploadrecords();
changecompany("IIM")
this.uploadrecords();
}
if(curext() == "IIM")
{
changecompany("ILF")
this.uploadrecords();
changecompany("IFN")
this.uploadrecords();
}
/*insertion of same record into other company ends*/
changecompany(curext())
// Modified on 05 Aug 2010 at 11:53:14 by Hemant - End
i++;
}
ttscommit;
if (j > 0 && k > 0 && l>0)
info(strfmt('%1(ILFS), %2(IFIN) ,%3(IIML) records are uploaded in %4 table.',j,k,l,tableName));
}