SST String is Nil

Questions and answers on how to use XLSReadWriteII 5.
Post Reply
rhwang46
Posts: 5
Joined: Sat Oct 08, 2005 3:48 am

SST String is Nil

Post by rhwang46 »

While I read a xlsx, the program generates an exception SST String is Nil. What seems the problem?
rhwang46
Posts: 5
Joined: Sat Oct 08, 2005 3:48 am

Re: SST String is Nil

Post by rhwang46 »

But if I save this particular file as xls format, then I could read (xvExcel97) it without problem. There are Chinese characters in the sheet which might be the problem. I have emailed the file to you.
Roman55
Posts: 10
Joined: Tue Mar 26, 2013 11:29 am

Re: SST String is Nil

Post by Roman55 »

I get the same error "SST String is Nil" when trying to format a single cell. The code is:

Code: Select all

  xlsRW := TXLSReadWriteII5.Create(nil);
  xlsRW.Filename := 'test.xlsx';
  with xlsRW[0] do
  begin
    AsString[0, 0] := 'Test string';
    with Cell[0, 0] do
    begin
      HorizAlignment := chaCenter;
      FontStyle := [xfsBold];
    end;
  xlsRW.Write;
  xlsRW.Free;
This way of formatting is documented in FormatCells sample. Using CmdFormat solves the problem, but it's inconvenient to write "BeginEdit()... Apply" every time I want to format just one cell.
What am I doing wrong?
Tested on 5.10.18, both 97 and 2007 modes affected. Call stack:

Code: Select all

:004778ac TXc12DataSST.UsesString + $28
:00477bfa TXLSCellMMU.SetStyle + $112
:00529183 TXLSCell.StyleChanged + $1F
PStadler
Posts: 44
Joined: Sat Feb 18, 2006 8:19 am

Re: SST String is Nil

Post by PStadler »

Hello,

I get this exception too, also reading an xls-File.

It did not happen with Version 4, but with all Versions of 5.

Sincerely

Peter
larsa
Site Admin
Posts: 926
Joined: Mon Jun 27, 2005 9:30 pm

Re: SST String is Nil

Post by larsa »

Hello

This is fixed in update 5.10.19
Lars Arvidsson, Axolot Data
mario
Posts: 8
Joined: Mon Feb 25, 2013 10:39 am

Re: SST String is Nil

Post by mario »

I have the same problem. I'm using delphi XE with the version 5.10.28

How is this possible?
mario
Posts: 8
Joined: Mon Feb 25, 2013 10:39 am

Re: SST String is Nil

Post by mario »

Hi, I'll try to explain better my own situation.

Sometimes I have to create one or two excel files, and everything going well.
I got SST String is Nil exception when I try to create a big number of different excel files (about 50) and during the generation my software changes the position of a few columns of each files.

The exception rises after the creation of 4-7 excel files.

As the time spent to generate is not a big problem, so I'm trying to find a way to reset the process, but I haven't found anything else than manually stop my program.

Any advice?

Thank you very much
larsa
Site Admin
Posts: 926
Joined: Mon Jun 27, 2005 9:30 pm

Re: SST String is Nil

Post by larsa »

Hello

I need something that I can reproduce in order to answer this.
Lars Arvidsson, Axolot Data
Post Reply