Sheet name length limitation

Posted by: ed on 27 September 2019, 5:22 am EST

  • Posted 27 September 2019, 5:22 am EST

    We are upgrading our application from version 9 to version 12 of Spread-WinForms. In our application we are opening .xml files saved in V9. We are getting an error message when files being opened have sheet names that exceed the 31 character sheet name limit that has been added to the SheetName property in V12.

    Do you have any suggested work arounds other an shortening the sheet name and resaving in the version of our app using V9 of Spread before trying to open in the V12 version.?

    Thanks, Ed
  • Replied 29 September 2019, 4:15 pm EST

    Hello,

    In case you want to by-pass this limitation, you can use the following code in the entry point of application:

    GrapeCity.Spreadsheet.WorkbookSet.Compatibility = 0;

    Hope it helps.

    Thanks,
    Mohit
  • Replied 30 September 2019, 4:20 am EST

    Hi Mohit,
    When I add that line of code I get a message saying

    "WorkBookSet is not a member of Grapecity.Spreadsheet"

    I am I missing a reference?
    Thanks, Ed
  • Replied 30 September 2019, 3:47 pm EST

    Hello,

    Please add the following dll in your project:

    GrapeCity.Spreadsheet

    Thanks,
    Mohit
  • Replied 1 October 2019, 3:49 am EST

    Hi,
    Thanks. That fixed that problem but I am still getting the same error message with I open the .xml file.
    Thanks, Ed
  • Replied 1 October 2019, 3:52 am EST

    I added the line of code you give me at the top of the Load event in my startup form.
  • Replied 2 October 2019, 5:39 pm EST

    Hello,

    You need to use this line before you loading the XML into Spread. Please refer to the attached project.

    f the problem still occurs them, Could you please either modify the attached application or provide your own stripped-down project so that I can try reproducing the same behavior at my end and assist you further accordingly?

    Thanks,
    Mohit
    Spread_Issue.zip
  • Replied 3 October 2019, 4:34 am EST

    I did place it before opening the .xml file. Let me work on it some more and if I don't have any success I will try to create a stripped down project as you suggested.
    Thanks, Ed
  • Replied 3 October 2019, 10:54 pm EST

    Hello,

    Sure! Take your time. I am waiting for your sample for further progress.

    Thanks,
    Mohit
  • Replied 16 October 2019, 5:00 am EST

    Hi Mohit,
    So to the solution you provided did fix the issue with the sheet name length. However, special characters such as "/", "*" in the sheet name are still giving me a
    problem. Should the GrapeCity.Spreadsheet.WorkbookSet.Compatibility = 0; deal with that issue too.
    Thanks, Ed
  • Replied 16 October 2019, 5:28 am EST

    I have attached a sample project where the sheet name includes a special character.SpreadTest.zip
  • Marked as Answer

    Replied 16 October 2019, 4:20 pm EST

    Hello,

    Sorry to mention that there is no workaround for special character. You need to rename the sheet using the OLD spread like as follows:

    Load the XML file with old version
    Rename the sheet to make all formulas to be adjusted automatically
    Save to XML file. Now all formulas have no special characters
    Load the new XML file with new version of Spread

    Sorry for the inconvenience caused.

    Thanks,
  • Replied 17 October 2019, 2:56 am EST

    Well thanks for responding. Not the answer I wanted to hear but I guess we know what we need to do now.
Need extra support?

Upgrade your support plan and get personal unlimited phone support with our customer engagement team

Learn More

Forum Channels