Quantcast
Channel: Adobe Community: Message List - FrameMaker Scripting
Viewing all articles
Browse latest Browse all 3715

Re: Retrieving data from Excel file

$
0
0

Hi,

 

I have been using an Excel file to handle the administration of a repository management system, with hundreds of entries going into the Excel sheet and being read from the sheet by management scripts. I know what it does to the performance of your application.

 

My word of advice on this: even though it is technically possible to access an Excel file directly to retrieve the data, I would steer clear of that option. The problem is that you create an enormous overhead for each single read operation on a cell in Excel (an ActiveX or other object must be created that can do almost anything you would ever want to do, including frying some eggs for breakfast).

 

The easy way of doing this: save your Excel sheet as CSV file (note that Excel really creates 'SSV' - semicolon separated variables - and does not tell you about this), then make your script read the file line by line as text and use the JavaScript split method to retrieve the separate cells from the original Excel sheet. Works fine, and fast. Several customers for my tailor-made CMS are using this method hundreds of times every day (without ever noticing it).

 

Good luck

 

Jang


Viewing all articles
Browse latest Browse all 3715

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>