技術文章 - CS216668

An example Afterloader hook method to add the Windchill version of EPM Documents to the name of output viewable files

修改時間: 06-Aug-2021   


套用到

  • Windchill PDM Essentials 10.1 M030 to 11.1 M010
  • Creo View Adapters 4.0 F000 to 8.0
  • Windchill PDMLink 10.1 M010 to 12.0
  • Visualization Services (wvs)

描述

  • After the EDRLoader successfully creates a new representation, a custom method can be called to perform additional work
    • For example, setting ad hoc permissions on the new representation. Refer to the publish.afterloadermethod property definition in the wvs.properties.xconf file in your Windchill installation for more details
  • This article provides sample code for this hook that will enable you to rename Additional files published via WVS Publish Rules to include source Windchill version number or save a copy of the content locally
  • One key element to know about this implementation before deploying in your system:
    • This article is intended to rename only additional files and NOT the primary viewable file. See CS333616 to understand the importance of this instruction.
  • This sample customization enables the following : Choose one of the following options
  • Afterloader Option 1
    • The AfterEDRloader hook method starts as a post publish job after WVS completes publishing of a new representation
    • Renames Additional files published via WVS Publish Rules to include source Windchill version number.  The output file names will be: source CAD file name + Windchill version number. i.e. Format: <CADName>_<IterationInfo>.extension (e.g. MYCADNAME_A.1.stp)
      • For Example)
User-added image
  • Or Afterloader Option 2 (This section moved to a new article CS348848)
  1. Creates a Copy of output viewable files (Primary or Additional file type in Representation) as EPMDocument attachments. The output file names will be: source CAD file name + Windchill version number. i.e. Format: <CADName>_<IterationInfo>.extension (e.g. MYCADNAME_A.1.stp)
    • ​For Example)
      User-added image

  2. Optionally download a copy of the EPM Document's attachments created at step 1 to a designated folder on a local or network hard disk on Windchill server
    • For example)
​​​User-added image
This is a PDF version of Article CS216668 and may be out of date. For the latest version https://www.ptc.com/tw/support/article/cs216668