[Web Previewer] Preview not working for .doc, .docx, .xlsx

[Web Previewer] Preview not working for .doc, .docx, .xlsx

  
Forge Component
(8)
Published on 25 Oct by Rui Mendes
8 votes
Published on 25 Oct by Rui Mendes

Hi,

brilliant component but it won't preview any documents/excel files I've uploaded.

I am using Office 365 but the File type associated with the file is the same as you are using in your example. However, I am not accessing files in the Resources section, I am actually uploading and storing the binary data in an entity and then binding the attributes to your structure. Is that the issue?

Images and pdfs preview with no issue.

Debra

 

Hi Debra

Please try the following:
When uploading your files to the database, make sure the filename contains the file extension (.docx / .xlsx) or the filetype contains the corresponding mime type ( .xlsx -> application/vnd.openxmlformats-officedocument.spreadsheetml.sheet )

Mapping the 'upload' widget attributes to the db should do the trick.

(Your entity's attributes should have enough length for 'filetype' and 'filename')

Let me know if it helped.

Cheers,

Rui Mendes


Debra Bodham wrote:

Hi,

brilliant component but it won't preview any documents/excel files I've uploaded.

I am using Office 365 but the File type associated with the file is the same as you are using in your example. However, I am not accessing files in the Resources section, I am actually uploading and storing the binary data in an entity and then binding the attributes to your structure. Is that the issue?

Images and pdfs preview with no issue.

Debra

 



Hi Rui,

All of the files I'm having issues with have the .docx or .xlsx and the correct mime type. I'm attaching a file I have also tried uploading and previewing which contains a screen shot of the Filename and extension of each of the files and the mime type.

I have just tried adding it to the resources in your sample app instead of the .docx document you have there and I get the same error. Is it because I'm using Office 365?

Debra

Hi Debra.

Please update the component and take a look at the sample.

I've updated it and tested your file in the sample page (Sample) and it is working.

Please take a look and let me know if it helped.


Cheers.



Debra Bodham wrote:

Hi Rui,

All of the files I'm having issues with have the .docx or .xlsx and the correct mime type. I'm attaching a file I have also tried uploading and previewing which contains a screen shot of the Filename and extension of each of the files and the mime type.

I have just tried adding it to the resources in your sample app instead of the .docx document you have there and I get the same error. Is it because I'm using Office 365?

Debra