TestEditExcel
Back to ListDescription: Alpha-test function to test import/export Excel documents.
FileMaker Prototype:
Set Variable [$res; ACF_Run("TestEditExcel";)]
Category: EXCEL
Function source:
Function TestEditExcel ()
/*
Alpha-test new import function for excel spreadsheets,
import an Excel spreadsheet, print cell A1 to console, and save the imported content to a new file.
The two files can be inspected for being equal as proof of correct import.
*/
string res, path = desktop_directory()+"ACF-Lib-listing.xlsx";
int wb = excel_open ( path, "r");
string h1 = excel_getcell(wb, 1, 1);
print h1+"\n";
excel_SaveAsWorkbook ( wb, desktop_directory()+"ACF-Lib_listing-Edited.xlsx");
excel_close (wb);
return "OK";
end
The TestEditExcel Function is Alpha-TEST function used under development of new Excel lib function for importing excel spreadsheets.
Example
Set Variable [$res; ACF_Run("TestEditExcel")]
The purpose is comparing the saved Excel file, to see that they are equal as a proof that the import works as expected.
