MIMEType for excel files (.xlsx) in JCR Node | Community
Skip to main content
DIPEN_SEN_
Level 3
Dec 4, 2019 11:20 AM UTC
Solved

MIMEType for excel files (.xlsx) in JCR Node

Hi,

I am trying to create a nt:file node for excel file. I am trying to add property of mimetype as "application/vnd.openxmlformats-officedocument.spreadsheetml.sheet".

But I am getting exception "javax.jcr.nodetype.ConstraintViolationException: No matching property definition: mimeType = application/vnd.openxmlformats-officedocument.spreadsheetml.sheet"

Code : node.setProperty("mimeType", mimeTypeService.getMimeType("xlsx"));

However if I upload an excel file in dam , jcr:content under original node has property "jcr:mimeType" with value "application/vnd.openxmlformats-officedocument.spreadsheetml.sheet"

Please provide some pointers.

This post is no longer active and is closed to new replies. Need help? Start a new post to ask your question.
arunpatidar
arunpatidarAccepted solution
New Participant
Dec 22, 2019 5:48 PM UTC

can you please check where are you adding the property, if it is nt unstructured node, then it should work

 

Arun Patidar

1 reply

arunpatidar
arunpatidarAccepted solution
New Participant
Dec 22, 2019 5:48 PM UTC

can you please check where are you adding the property, if it is nt unstructured node, then it should work

 

Translate
Arun Patidar