GNOME Bugzilla – Bug 166611
Names defined with another name do not load correctly from an Excel file
Last modified: 2005-05-25 15:18:51 UTC
Version details: 1.4.2 RC1 Hello, I tried to import an Excel 2000 file (that actually works fine in Excel, of course ;o) into Gnumeric, and it almost succeeded. Yes, only almost :o7 This Excel file loads but the name assigned to ranges that are defined according to another name are not properly "understood" and instead there is a reference error ("#REF!"). Here are the correct names in the Excel sheet: data offset(Feuil1!$B$3;0;1;1;min(fen_graph;counta(Feuil1!$3:$3)-2)) fen_graph Feuil1!$A$25 de_0_à_4 offset(Feuil1!$B$4;0;1;1;min(fen_graph;counta(Feuil1!$4:$4)-1)) de_5_à_9 offset(Feuil1!$B$5;0;1;1;min(fen_graph;counta(Feuil1!$5:$5)-1)) de_10_à_14 offset(Feuil1!$B$6;0;1;1;min(fen_graph;counta(Feuil1!$6:$6)-1)) de_15_à_19 offset(Feuil1!$B$7;0;1;1;min(fen_graph;counta(Feuil1!$7:$7)-1)) de_20_à_24 offset(Feuil1!$B$8;0;1;1;min(fen_graph;counta(Feuil1!$8:$8)-1)) Min1 Feuil1!$A$17 Min2 Feuil1!$A$18 Min3 Feuil1!$A$19 Min4 Feuil1!$A$20 Min5 Feuil1!$A$21 Min6 Feuil1!$A$22 When the Excel file is loaded into Gnumeric, in every name that uses the name "fen_graph", this name is replaced by an error on the reference "#REF!". When I manually replace those "#REF!" by the proper name (that's "fen_graph", of course), Gnumeric properly displays the graph that is built using those names! (which means that Gnumeric is indeed very compatible with Excel: great job!) But, this correct content cannot be saved in either Gnumeric or Excel format or at least when loading the resulting file(s) the result is still incorrect :o( For example, when loading the gnumeric format file, none of the names that use the "fen_graph" name inside its definition is present: only "fen_graph", "Min1" to "Min6" are defined... As this problem is fairly complicated (and very graphic) to describe, I set up a web page (with a ton of gorgeous graphics and an Excel file) just for ya :o) Here it is: http://alv.free.fr/gnumeric_bug/index.html Have a nice day.
blah! When I wrote the code I was afraid of this situation but could not create a workbook that triggered this. I'll have a look.
I imagine we need a two-pass algorithm: first pass just defines the name with a dummy value, seconds pass changes to the proper value. That should make sure all needed names are defined before they are used. Even if someone manages to have circular definitions.
I'll take a crack at this now.
Seems fixed in cvs.