I'm trying to print out a .doc-File with com4j. This is my Code:
document.printOut2000(true, false, WdPrintOutRange.wdPrintAllDocument, newDocumentPath, _, _, WdPrintOutItem.wdPrintDocumentContent, 1, _, WdPrintOutPages.wdPrintAllPages, true, true, _, false, 0, 0, 0, 0);
I got the values from a recorded Word-Macro and http://msdn.microsoft.com/en-us/library/microsoft.office.tools.word.document.printout(v=VS.80).aspx
But all i get is the following error:
An unexpected error has been detected by Java Runtime Environment:
EXCEPTION_ACCESS_VIOLATION (0xc0000005) at pc=0x770f48f9, pid=3792, tid=5996
Java VM: Java HotSpot(TM) Client VM (11.0-b16 mixed mode, sharing windows-x86) Problematic frame: C [OLEAUT32.dll+0x48f9]
Any idea how i can solve this?
Edit: Com4j is opening the document, so I think the results of the previous methods aren't the problem, but thanks to DTH for the hint.