[fpc-pascal] Spreadsheet library/unit?
    Frank Peelo 
    f26p at eircom.net
       
    Sun Oct  5 23:48:26 CEST 2008
    
    
  
Antal wrote:
> You might use the CSV, which can be easily open with Office and to 
> generate by your application.
> I am using this way to handle data to/from excel
> It is a plain text file, each row is separated with CRLF (#13#10), each 
> cell separated with tab (#9)
errm, surely that should be a comma, not a tab!
> Also, if you'r data has no comma or " then you can use the real CSV, 
> because CSV means Comma Separated Values :)
You can use CSV with data which contains commas and quotes. Fields which 
contain "dodgy" characters, including commas, quotes, leading and 
trailing spaces, must be surrounded by quotes. If a field contains quote 
chars, the quote char is doubled:
"one ","two,buckle","""my""","shoe"
first field has a trailing space, second contains a comma (and 2 words), 
third is quoted and OpenOffice Calc seems to have quoted the fourth just 
for the heck of it.
> But the tab separated one can be easily pasted to/from Excel, by using 
> let's say notepad.
> You can experience this, since each Office behaves differently with the CSV.
Truth! But most spreadsheets can handle the above format.
Frank
    
    
More information about the fpc-pascal
mailing list