static void exportVendorToExcelTEST1(Args _args)
{
SysExcelApplication SysExcelApplication;
SysExcelWorksheet SysExcelWorksheet;
SysExcelWorksheets SysExcelWorksheets;
SysExcelWorkbooks SysExcelWorkbooks;
SysExcelWorkbook SysExcelWorkbook;
SysExcelRange SysExcelRange;
SysExcelCell SysExcelCell;
SysExcelCells SysExcelCells;
COMVariant COMVariant1;
Kriterler kriterler;
VendTable vtab;
Dialog dialog = new Dialog();
DialogField dflItem = dialog.addField(typeid(VendAccount));
#excel
;
while select vtab
where vtab.AccountNum like "S0000*"
{
try
{
sysExcelApplication = SysExcelApplication::construct();
sysExcelApplicatioN.displayAlerts(FALSE);
sysExcelApplication.visible(FALSE);
sysExcelWorkbooks = sysExcelApplication.workbooks();
// for filename
sysExcelApplication.workbooks().open("C:\\"+vtab.AccountNum+".XLS");
sysExcelWorkbook = sysExcelApplication.workbooks().item(1);
SysExcelWorksheets = sysExcelWorkbook.worksheets();
SysExcelWorksheet = SysExcelWorksheets.itemFromNum(1);
SysExcelRange = SysExcelWorksheet.cells().range(#ExcelTotalRange);
SysExcelCell = SysExcelWorksheet.cells().item(1,1);
SysExcelCell.value(systemdateget());
SysExcelCell = SysExcelWorksheet.cells().item(2,2);
SysExcelCell.value(vtab.AccountNum);
sysExcelApplication.save();
sysExcelApplication.quit();
}
catch (exception::Error)
{
}
}
}
30 Temmuz 2008 Çarşamba
Kaydol:
Kayıt Yorumları (Atom)
Hiç yorum yok:
Yorum Gönder