Community Tip - Want the oppurtunity to discuss enhancements to PTC products? Join a working group! X
We are trying to configure a custom Windchill worker to generate Creo View Representations in PDF format
of AutoCAD dwg, dxf files referring to this article: https://www.ptc.com/en/support/article/CS40919
We are currently experiencing an error: "..cannot produce output file xxx.out ".
How to solve this problem?
Hi Valdi,
Were you able to configure the AutoCAD worker
Hi Validi,
Followed the article https://www.ptc.com/en/support/article/CS40919. Able to configure worker and turn on.
The good part is it's trying to publish as well, however, the hurdle is accorconsole.exe is not creating any pdf.
If I place a dummy .pdf file in ftp folder created the representation is getting generated.
Tried to have a deep dive and found some bottleneck.
AutoCADWorker.bat triggers -> workerjava.bat which triggers -> customgenericeworker.java which triggers -> pdfconvertor.bat which actually picks up the .dwg from FTP folder and creates .pdf in the same folder. Then windchill worker picks up the pdf to create representation. ( The said files are provided in CS40919.)
Tried manually publishing pdf using accorconsole, creating bat script it's working fine.
The script from pdfconvertor.bat file
%CONVERTER% /i %1 /s %2 /l > AcCoreConsole.log 2>&1.
In this script where do we find %1 and %2 value defined? Any idea.
Hi @DKWc
Edit the bat file and add a line
echo /i %1 /s %2 > c:\logpdfconvertor.log
this will show you the values if the script is run.
you will find it in c:\logpdfconvertor.log file. Sure you can point to an another location.
PetrH
Hi @HelesicPetr ,
Thanks for the reply.
From where and we can reset/change the values?
Hi @DKWc
Who knows. You need to find it.
If you know values, you can search for it.
For example try to search a string values in all files and so on. If you are lucky you will find them.
I advice you how to get the value, now it is up to you to find the location where are defined.
PS: you find that the bat file is run from customgenericeworker.java so in this class there are the variables I guess.
PetrH
Hi All,
Seems the efforts finally paying off. The pdf is getting generated in the tmp folder however it comes with the suffix "-model".
Eg 56GF-Model.pdf , due to this the server is not able to pick the pdf file and generate representation.
If manually delete the suffix from pdf generated representation is getting generated.
The scr been used is attached.
Tried multiple ways still, suffix is getting generated.
Any suggestions on how to get rid of the suffix?
thanks in advance.
Regards,
Durga
Hi,
Thanks for the reply.
The proposed case is to rename the representations which are generated.
The actual scenario is the representation is not getting generated because the published pdf with the use of accoreconsole has a suffix that stops Windchill to pick up the published pdf from the temp folder. (EPM doc name and published pdf name differs due to suffix, which doesn't generate representation.)
If the suffix gets eliminated representation is generated.
Regards,
Durga
Hi @DKWc
My bad, I thought that the representation is created without pdf so my idea with WVS Afterloader can not work.
There has to be some configuration where the suffix is defined... for example publish rules CS111916 where suffix or prefix is set for additional files.
what PTC support tells you?
PetrH
Hi @DKWc
the case describes a script to add
Can you use this place for renaming the generated PDF? Or somewhere else?
PetrH
You could try using ‘EXPORT’ in the scr instead of PLOT, export is like save as pdf rather than print a pdf, I used export for custom autocad workers and the pdf file name is the same as the drawing number + .pdf
Hi,
Thanks for your reply.
If manually use export in AutoCAD UI it doesn't generate any prefixes or suffixes.
Any sample file scr you have for export.
Regards,
Durga
Hi @DKWc
Use EXPORT instead of PLOT in your configuration
Also I would play with the script that cares about pdf name
PetrH
Sure, see attached.
In our case, we export only the paperspace views to PDF,
This script exactly worked for me.
Thanks HART you were popped in at exact right time.
This is working exactly as expected.
The publication is working fine.