Can not open xlsx successfully with MSExcel

Questions and answers on how to use XLSReadWriteII 5.
Post Reply
Seeker
Posts: 6
Joined: Tue Jan 05, 2016 1:25 am

Can not open xlsx successfully with MSExcel

Post by Seeker »

Hi,
I am creating a project with Delphi 7, MSSql 2000 in which the user is able to draw the content of a database and export it in an xlsx file.
Now, I put in a form an XLSReadWriteII 5 object (which I named XLappSun) and execute the following code in order to create the xlsx file:

Code: Select all

XLappSun.Clear;
Then I create a loop in which I query the possible data of my only one table "CredentialT" and until the end of the loop I put in each cell the appropriate data by executing the code:

Code: Select all

XLappSun.Sheets[0].AsString(Column, Row)
Last I save the xlsx I created executing the code:

Code: Select all

XLappSun.SaveToFile('c:\kpapas\kiki100.xlsx');
Now I have to note that the data in "CredentialsT" table belong to ASCII encoding and moreover even though the password column is somehow encrypted using alternation algorithms there is no corrupt data in it.
Now, if I preview the "kiki.xlsx" file with a XLSSpreadSheet component then I can see the data exactly as they are.
However if I open the "kiki.xlsx" with OpenOffice then I see only half of the data and, much worse, if I open it with MSExcel 2013 I can see only the data of integer type.

WHY is this happening and what can I do to in order to be able and inspect the file not only through XLSSpreadSheet but also through openoffice or MSExcel ?

Thank you in advance

P.S.: I would like to attach both the "kiki.xlsx" file as well as my database file (with only CredentialsT table for testing purposes ), but I can't see how to attach these files.
With them the whole problem would be much more easily to understand. Is there any way to attach them ?
Seeker
Posts: 6
Joined: Tue Jan 05, 2016 1:25 am

Re: Can not open xlsx successfully with MSExcel

Post by Seeker »

In my initial post / request for help, I wanted to say that with the project I am building the user can extract the data from specific tables of one of his Databases and export them to an xlsx file that is created with the XLSReadWriteII 5 component.
Post Reply