Data get render on Desktop Excel using office.js, but on Chrome Office 365 its give an error “There was an error processing the request.”

不想你离开。 提交于 2021-01-28 03:31:19

问题


We are using Office js library to render data on excel. There are more than 2000 rows that works fine on Desktop Excel. But when same API is used on Chrome office 365 it gives error message "There was an error processing the request."

Please see attached screenshot.

As data get larger Chrome Office excel is not able to render data. Please help us as this is blocker in our application and our production is getting effected.


回答1:


There are 2 limitations when interacting with Excel workbook When you're building an Excel add-in

  • Excel on the web has a payload size limit for requests and responses of 5MB. RichAPI.Error will be thrown if that limit is exceeded.
  • A range is limited to five million cells for get operations.

Based on your description, it looks to me that you are hitting payload size issue. I would suggest to check the data before calling context.sync(). Split the operation into smaller pieces as needed. Be sure to call context.sync() for each sub-operation to avoid those operations getting batched together again.

Another tip is to leverage RangeAreas to strategically update cells within a larger range. See Work with multiple ranges simultaneously in Excel add-ins for more information.



来源:https://stackoverflow.com/questions/63599988/data-get-render-on-desktop-excel-using-office-js-but-on-chrome-office-365-its-g

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!