This is a migrated thread and some comments may be shown as answers.

Error saving and reopening saved file - The given key was not present in the dictionary

11 Answers 262 Views
Spreadsheet
This is a migrated thread and some comments may be shown as answers.
PabloFacture
Top achievements
Rank 1
PabloFacture asked on 12 Nov 2013, 09:44 PM
Cause:
I have several excel spreadsheets (xslx) which are given to customers as templates for them to open and start adding extra information. Such information is saved to a separate file. The issue is that when customers open their file, it displays the following error message:

The given key was not present in the dictionary

I even tried one of my templates on your demo online for Silverlight RadSpreadsheet and it does not work either:

http://demos.telerik.com/silverlight/#Spreadsheet/FirstLook

Updates to most of the excel files I have as templates for customers do not work either.

On the link below you can find a PDF with a walk-through (screenshots) of a demo reproducing the error.

Screenshots Reproducing Bug - Key Not Present Dictionary.pdf
http://sdrv.ms/1i77dav

Steps to reproduce the bug:

1. Open page with Silverlight radspreadsheet (e.g. http://demos.telerik.com/silverlight/#Spreadsheet/FirstLook)
2. Open an existing excel file. You can use the one below.

Open this file - Make changes - Save - Close - Reopen.xlsx
http://sdrv.ms/17mNPik

3. Make a change. I updated cell A1 with "abc".
4. Save changes to a second file.
5. Open file back up.
6. You'll get a beautiful "The given key was not present in the dictionary" error message.

This is a stopping point for our project as we already got on board using these controls. Can you please give a hand real quick?

11 Answers, 1 is accepted

Sort by
0
Nikolay Demirev
Telerik team
answered on 14 Nov 2013, 03:24 PM
Hello,

Thank you for writing and thank you for the detailed explanation.

We have managed to fix the bug you reported. The fix will be included in the next internal build, which will be available next week.

The issue was caused by the rich text contained in some cells in the document. Please bear in mind that for the time being RadSpreadsheet does not support rich text content in cells and it is ignored.

Regards,
Nikolay Demirev
Telerik
TRY TELERIK'S NEWEST PRODUCT - EQATEC APPLICATION ANALYTICS for SILVERLIGHT.
Learn what features your users use (or don't use) in your application. Know your audience. Target it better. Develop wisely.
Sign up for Free application insights >>
0
PabloFacture
Top achievements
Rank 1
answered on 20 Nov 2013, 06:09 PM
Hi, can you please confirm the bug was fixed so that we can proceed downloading the next internal build? If so, can you provide the build number?

Thanks!
0
Nikolay Demirev
Telerik team
answered on 21 Nov 2013, 12:00 PM
Hi,

The bug was fixed and the fix is included in the 2013.3.1118 build. You can download it from your Telerik profile after logging in.

Please note that internal builds are intended for testing purposes and we do not recommend them for production. Our next official release - Q3 SP1 2013, is expected in a couple of weeks.

Regards,
Nikolay Demirev
Telerik
TRY TELERIK'S NEWEST PRODUCT - EQATEC APPLICATION ANALYTICS for SILVERLIGHT.
Learn what features your users use (or don't use) in your application. Know your audience. Target it better. Develop wisely.
Sign up for Free application insights >>
0
PabloFacture
Top achievements
Rank 1
answered on 26 Nov 2013, 02:21 PM
I have tested the fix and is not quite right. Customers are experiencing issues while using the RadSpreadsheet Silverlight control. Indeed, it is not throwing an error. However, all custom data they entered to our excel templates are lost when they have some sort of formatting (I guess it is considering it as RTF). Basically, all cells on which customers enter data and apply bold, italic, different font size or color, underline, and the like. Such data is completely lost when reopening a previously saved document.

You can use the same excel document posted above and reproduce with the same steps.

This is defeating the purpose of adding the control to our application and a bit embarrassing while doing a presentation to customers.

The expected behavior is to have customers' custom data saved after opening and editing the application's excel spreadsheets. This functionality is on the critical path of our application. Can you please let me know whether this can be implemented? Based on your response, we will have to make a decision on our project in terms on how to achieve this customer requirement.
0
Petya
Telerik team
answered on 28 Nov 2013, 04:30 PM
Hello,

We are not sure we understand your scenario properly.

As far as I understand, these are the steps that cause the problem you are observing. Could you please verify that?
  • Importing the document from your first reply in a project targeting the LIB version of RadControls.
  • Applying formatting to one (or many) of the cells, i.e. clicking the FORMATO cell and then Bold, Italic, etc. buttons on the ribbon.
  • Exporting the document to XLSX.
  • Upon importing it back in the same application, the data from the cell is missing.

I tried executing those steps with the mentioned version and everything seems to work as expected.

As to rich text, setting cell formatting is not part of the rich-text concept. If you look at your document, you might notice on the bottom a cell which contains a bold word ("Note") and then some non-bolded content. Such content is considered rich-text and is currently ignored by the control on import. However, you should not be able to create similar setup in RadSpreadsheet and export it, since once you select only part of the content in a cell (in the formula bar) the buttons on the ribbon are disabled.

Please try to provide details on the problem you are facing and we will gladly address it.

Regards,
Petya
Telerik
TRY TELERIK'S NEWEST PRODUCT - EQATEC APPLICATION ANALYTICS for SILVERLIGHT.
Learn what features your users use (or don't use) in your application. Know your audience. Target it better. Develop wisely.
Sign up for Free application insights >>
0
Sergio
Top achievements
Rank 1
answered on 28 Nov 2013, 09:07 PM
I have the same problem as Mr PabloFacture reported earlier, I have attached two pictures in which you can see the problem.

1. In the excel in row A37, we typed text (excel file.png).
2. We test the same file on the telerik page demo and the same row (A37) is empty (error.png).
3. We test the same file on the 2013.3.1118 build and the same row (A37) is empty.

The following is the link to the original file for your tests.
https://drive.google.com/file/d/0B0KaGWCwzokpdUQ1ek9tbDBvMVE/edit?usp=sharing
0
Petya
Telerik team
answered on 29 Nov 2013, 03:28 PM
Hi,

As previously said, the initial issue causing an error when you try to import the file is already fixed and the fix will also be included in the upcoming in a couple of days service pack.

When it comes to the missing content when testing this with the LIB, at this point there is not much we can do. Supporting rich text in cells is in our to-do list, however we haven't set a particular date for its implementation. Our development plans greatly depend on client's feedback, so rest assured that your needs are taken into account and we will do our best to introduce this feature as soon as possible.

Let us know if you have any other questions.

Regards,
Petya
Telerik
TRY TELERIK'S NEWEST PRODUCT - EQATEC APPLICATION ANALYTICS for SILVERLIGHT.
Learn what features your users use (or don't use) in your application. Know your audience. Target it better. Develop wisely.
Sign up for Free application insights >>
0
Robert
Top achievements
Rank 1
answered on 06 Jan 2014, 04:25 PM
I have the same problem, but I am using the WPF version of RadSpreadsheet.  Is there an update that I can download, as I am trying to evaluate your product for consideration.

Thanks,
Rob
0
Petya
Telerik team
answered on 09 Jan 2014, 12:26 PM
Hi Rob,

I checked your account and the version of RadControls for Silverlight you've downloaded should contain the fix discussed in this thread. We would appreciate if you send us the problematic document, so that we can further investigate this.

We're looking forward to hearing from you.

Regards,
Petya
Telerik
TRY TELERIK'S NEWEST PRODUCT - EQATEC APPLICATION ANALYTICS for SILVERLIGHT.
Learn what features your users use (or don't use) in your application. Know your audience. Target it better. Develop wisely.
Sign up for Free application insights >>
0
sai
Top achievements
Rank 1
answered on 24 Mar 2015, 05:33 PM
Even I'm getting the same exception... I'm using latest dlls
Please find the attachment to reproduce the issue
Rename the extension from png to Xlsx
0
Tanya
Telerik team
answered on 27 Mar 2015, 03:15 PM
Hello Sai,

Thank you for your question.

We have already addressed your issue in the forum thread where you posted about it. You can find the answer following this link.

Regards,
Tanya
Telerik
 

See What's Next in App Development. Register for TelerikNEXT.

 
Tags
Spreadsheet
Asked by
PabloFacture
Top achievements
Rank 1
Answers by
Nikolay Demirev
Telerik team
PabloFacture
Top achievements
Rank 1
Petya
Telerik team
Sergio
Top achievements
Rank 1
Robert
Top achievements
Rank 1
sai
Top achievements
Rank 1
Tanya
Telerik team
Share this question
or