Reading cached external fields from excel file, the results are different from what I see in excel

I am trying to read an excel file using xlrd in python3, but I am not getting results from reading cells since I see them in excel.

It seems that the cell I'm trying to access has some external source from which they are updated, but since this source is not available to me, excel displays some cached values. These values ​​are located elsewhere in the same excel file, so in the sheet that you see, for example, "2.65111" the actual contents of the cell are displayed as "= BC12" in this edit panel in excel.

When I try to read this via xlrd, for example:

wb=xlrd.open_workbook("filename.xls",formatting_info=True)
wb.sheet_by_name("sheetname").cell(12,9)

The contents of the cell are displayed as:

'text:'[XXXX]' (XF:95)'

(where XXXX is most likely the column name of this external CSV file)

I would either expect xlrd to return "2.65111". I see in excel or at least "= BC12" as a link to another cell, but I just can't use the "thing [XXXXX]",

Is there a way to get xlrd to show either of these two?

I am really confused about where it has this "[XXXXX]" and why it is so different from what I see in excel.

PS: I can’t just use the data from the BC12 cell, since this should be automatic file processing, and only the “original” cells have a fixed position, and these others can just be in a different random position, the next day.

+5
source share
3 answers

, excel, , .

, , " " - .

+1

" 12,9" Excel J13 ( J12). , ? , J13 BC12? -, J13 BC12?

0

Perhaps your only option is to pre-process the file using Excel through the Excel COM API. You can do something simple in .NET that downloads an excel file, receives the data and saves it in a similar structured excel file, but without external links. Downloading an excel file using Excel takes a lot of time (a few seconds) and, of course, will not work if you reload it on the server, but if you have several files per day, it will work. Of course, this will not work if you are not working on Windows.

0
source

All Articles