Skip to main content
1-Visitor
June 8, 2017
Question

How to change Type of EPMDocument type in batch mode?

  • June 8, 2017
  • 2 replies
  • 5152 views

Hi

We have some EPMDocuments as "DefaultEPMDocument" type in a Particular Library.

How we can change all the data in this particular library to some other SubType, say "StandardPartType"

As of now i can change one item at a time using "wt.epm.util.SoftTypeChangeUtility"

1. how can i change items of a particular library in batch mode?

2. how can i pass username password in single document mode command itself?

Thank you.

//Rakesh

2 replies

13-Aquamarine
June 9, 2017

Hi Rakesh,

Go to the PTC Knowledge Base for Windchill and look up "ChangeTypeSql".  This is a simple java class that you can request and install on your Windchill system that you can use to change the soft type of any object within Windchill.  You cannot change from one modeled type to another but you can change soft types.  For example you can change a WTDocument to a ReferenceDocument but you cannot change an EPMDocument to a WTPart.

Hope It Helps,

Patrick Williams

rkumar-101-VisitorAuthor
1-Visitor
June 9, 2017

Hi Patrick

Document - CS52368

  • This utility is not support for EPMDocuments and subtypes as using this tool might cause data corruption.
  • Use the wt.epm.util.SoftTypeChangeUtility instead.

//Rakesh

15-Moonstone
October 6, 2023

Hi Rakesh,

Did you find a way to do this? I'm struggling with the same problem myself.

I need to change the Subtype of all the EPMDocuments except the ones in a particular library. More specifically, I need to change all the Solidworks CAD Documents to new Subtype except Solidworks Toolbox CAD documents which are in their own library. If there was a way to change the type of objects in a specific context I could change all objects to the new type and then change only the Toolbox library back to the original type.

17-Peridot
October 6, 2023

There is also a single document mode, where you need to enter the CAD name.

See Single Document Mode 

With this option you could change all the Toolbox CAD Documents to another subtype, change all the rest and move the others back to the current one. The easiest way is to create a query builder report with the CADName and process all of them.

If you have thousands of toolbox documents, the runtime could be the problem for single mode.

15-Moonstone
October 6, 2023

Hi Björn,

The problem with the single document mode is that it asks for login in a popup every time the tool is run. So even if I made a batch script for going through all the CAD files, it seems that I would need to re-enter the login info for each object being processed.