Error during export to word

Hi all,

when trying to Export to word I run into a Java-ClasscastException when a style in my word template is used.

Because style-mappings from confluence to word did not work as expected

I used the tip-Macro and defined a style "Scroll Tip" in Word.

Is there a specific way to define a "table style" ?

Somehow it is having something to do with the type of style.

 

Thanks!

Cheers

Bjoern

 

com.k15t.scroll.core.extension.exporter.ExporterException: Failed to add trailing paragraph.

at com.k15t.scroll.words.exporter.AbstractWordsExporter.finalProcessing(AbstractWordsExporter.java:470)

at com.k15t.scroll.words.exporter.DocxExporter.finalProcessing(DocxExporter.java:101)

at com.k15t.scroll.words.exporter.AbstractWordsExporter.save(AbstractWordsExporter.java:443)

at com.k15t.scroll.words.exporter.DelegatingWordsExporter.save(DelegatingWordsExporter.java:117)

at com.k15t.scroll.confluence.model.export.ExportLogic$6.doInTransaction(ExportLogic.java:453)

at com.k15t.scroll.confluence.model.export.ExportLogic$6.doInTransaction(ExportLogic.java:448)

at com.atlassian.sal.core.transaction.HostContextTransactionTemplate$1.doInTransaction(HostContextTransactionTemplate.java:21)

at com.atlassian.sal.spring.component.SpringHostContextAccessor$1.doInTransaction(SpringHostContextAccessor.java:71)

at org.springframework.transaction.support.TransactionTemplate.execute(TransactionTemplate.java:133)

at com.atlassian.sal.spring.component.SpringHostContextAccessor.doInTransaction(SpringHostContextAccessor.java:68)

at com.atlassian.confluence.spring.transaction.interceptor.ConfluenceSpringHostContextAccessor.access$001(ConfluenceSpringHostContextAccessor.java:21)

at com.atlassian.confluence.spring.transaction.interceptor.ConfluenceSpringHostContextAccessor.lambda$doInTransaction$3(ConfluenceSpringHostContextAccessor.java:72)

at com.atlassian.confluence.impl.vcache.VCacheRequestContextManager.doInRequestContext(VCacheRequestContextManager.java:82)

at com.atlassian.confluence.impl.vcache.VCacheRequestContextManager.doInRequestContext(VCacheRequestContextManager.java:72)

at com.atlassian.confluence.spring.transaction.interceptor.ConfluenceSpringHostContextAccessor.doInTransaction(ConfluenceSpringHostContextAccessor.java:72)

at sun.reflect.GeneratedMethodAccessor250.invoke(Unknown Source)

at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)

at java.lang.reflect.Method.invoke(Method.java:498)

at com.atlassian.plugin.util.ContextClassLoaderSettingInvocationHandler.invoke(ContextClassLoaderSettingInvocationHandler.java:26)

at com.sun.proxy.$Proxy286.doInTransaction(Unknown Source)

at sun.reflect.GeneratedMethodAccessor250.invoke(Unknown Source)

at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)

at java.lang.reflect.Method.invoke(Method.java:498)

at com.atlassian.plugin.osgi.bridge.external.HostComponentFactoryBean$DynamicServiceInvocationHandler.invoke(HostComponentFactoryBean.java:136)

at com.sun.proxy.$Proxy286.doInTransaction(Unknown Source)

at com.atlassian.sal.core.transaction.HostContextTransactionTemplate.execute(HostContextTransactionTemplate.java:18)

at sun.reflect.GeneratedMethodAccessor253.invoke(Unknown Source)

at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)

at java.lang.reflect.Method.invoke(Method.java:498)

at org.springframework.aop.support.AopUtils.invokeJoinpointUsingReflection(AopUtils.java:302)

at org.eclipse.gemini.blueprint.service.importer.support.internal.aop.ServiceInvoker.doInvoke(ServiceInvoker.java:56)

at org.eclipse.gemini.blueprint.service.importer.support.internal.aop.ServiceInvoker.invoke(ServiceInvoker.java:60)

at org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:179)

at org.springframework.aop.support.DelegatingIntroductionInterceptor.doProceed(DelegatingIntroductionInterceptor.java:133)

at org.springframework.aop.support.DelegatingIntroductionInterceptor.invoke(DelegatingIntroductionInterceptor.java:121)

at org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:179)

at org.eclipse.gemini.blueprint.service.util.internal.aop.ServiceTCCLInterceptor.invokeUnprivileged(ServiceTCCLInterceptor.java:70)

at org.eclipse.gemini.blueprint.service.util.internal.aop.ServiceTCCLInterceptor.invoke(ServiceTCCLInterceptor.java:53)

at org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:179)

at org.eclipse.gemini.blueprint.service.importer.support.LocalBundleContextAdvice.invoke(LocalBundleContextAdvice.java:57)

at org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:179)

at org.springframework.aop.support.DelegatingIntroductionInterceptor.doProceed(DelegatingIntroductionInterceptor.java:133)

at org.springframework.aop.support.DelegatingIntroductionInterceptor.invoke(DelegatingIntroductionInterceptor.java:121)

at org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:179)

at org.springframework.aop.framework.JdkDynamicAopProxy.invoke(JdkDynamicAopProxy.java:208)

at com.sun.proxy.$Proxy2105.execute(Unknown Source)

at com.k15t.scroll.confluence.model.export.ExportLogic.save(ExportLogic.java:448)

at com.k15t.scroll.confluence.model.export.ExportLogic.createExportArtifact(ExportLogic.java:424)

at com.k15t.scroll.confluence.model.export.ExportLogic.performExport(ExportLogic.java:137)

at com.k15t.scroll.confluence.model.export.ExportTask.call(ExportTask.java:158)

at com.k15t.scroll.confluence.model.export.ExportTask.call(ExportTask.java:56)

at java.util.concurrent.FutureTask.run(FutureTask.java:266)

at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1142)

at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:617)

at java.lang.Thread.run(Thread.java:745)

Caused by: com.k15t.scroll.core.extension.exporter.ExporterException: messages.asposeexception.setstyleonparagraph

at com.k15t.scroll.words.DocumentBuilder.startTableParagraphStyle(DocumentBuilder.java:414)

at com.k15t.scroll.words.DocumentBuilder.startParagraph(DocumentBuilder.java:348)

at com.k15t.scroll.words.DocumentBuilder.startParagraph(DocumentBuilder.java:301)

at com.k15t.scroll.words.exporter.AbstractWordsExporter.finalProcessing(AbstractWordsExporter.java:467)

... 54 more

Caused by: java.lang.ClassCastException

1 answer

Hi,

found the answer myself, following

https://support.office.com/en-us/article/Apply-table-styles-0f19e350-f9a1-4a9f-afdb-46ee2bb8460c

When specifying a correlating table style the Export does not fail.

Best regards,

Bjoern

Suggest an answer

Log in or Sign up to answer
Atlassian Community Anniversary

Happy Anniversary, Atlassian Community!

This community is celebrating its one-year anniversary and Atlassian co-founder Mike Cannon-Brookes has all the feels.

Read more
Community showcase
Kesha Thillainayagam
Posted Apr 13, 2018 in Confluence

We want to hear how your non-technical teams are using Confluence!

Hi Community! Kesha (kay-sha) from the Confluence marketing team here! Can you share stories with us on how your non-technical (think Marketing, Sales, HR, legal, etc.) teams are using Confluen...

2,829 views 27 11
Join discussion

Atlassian User Groups

Connect with like-minded Atlassian users at free events near you!

Find a group

Connect with like-minded Atlassian users at free events near you!

Find my local user group

Unfortunately there are no AUG chapters near you at the moment.

Start an AUG

You're one step closer to meeting fellow Atlassian users at your local meet up. Learn more about AUGs

Groups near you