cancel
Showing results for 
Search instead for 
Did you mean: 
cancel
Showing results for 
Search instead for 
Did you mean: 

Community Tip - Learn all about the Community Ranking System, a fun gamification element of the PTC Community. X

How to see number of sheets in a Drawing from Windchill without opening the file?

icelynnin
12-Amethyst

How to see number of sheets in a Drawing from Windchill without opening the file?

Version: Windchill 13.0

 

Use Case: The number of sheets/pages on a drawing is not visible in a drawing's windchill object page, and can only be seen once opened in Creo View or when opening the drawing content in Creo.


Description:

Is there a simple way to make a drawing's page count visible on the object info page?

i.e. the number of sheets in a drawing.

 

I can imagine a custom attribute and custom java code that interrogates the drawing file content to come up with a sheet count, but wondered if there is anything out of the box.
Could it even be a matter of having the thumbnail render with a sheet count or indicator that it is multiple sheets (or how many sheets)?

6 REPLIES 6
BenLoosli
23-Emerald II
(To:icelynnin)

Probably can do it with a simple relation and parameter/attribute.

The drawing has &total_sheets parameter that could be set to a designated attribute. Then modify the Information page to include the attribute.

It might require a relation and as we all know, drawings do NOT allow relations! This has been an Idea for years.

avillanueva
22-Sapphire II
(To:BenLoosli)

It would work but never a big fan of those type of solutions. It adds to much complexity. @icelynnin What's your use case? How would that information be used? The system has the information. It should be able to read the file and figure that out. 

It seems since &total_sheets is a label/system function that it cannot be used in properties, relations or even be designated.

 

https://www.ptc.com/en/support/article/CS155176?source=search

 

If you have another way of setting it as a designated attribute- as with that simple flag enabled it would be very easy to pull it into windchill.

I have to agree with @avillanueva, the &total_sheets and a designated parameter seems like a lot of work for something that's pretty simple to do using Java.

 

If the need is to simply know how many sheets, why not simple write code that finds the drawing file in the vault and read it to get the number of sheets.

This number could be pumping into a Windchill attribute automatically upon checkin.

 

Or if this does not really need to be in the dB, a calculated attribute could be used to display the number of sheets.

If on demand is desired a custom action could be setup that displays the number of sheets to the user when they select the action.

 

Also, if you use a Java solution you can get more than just the number of sheets from the drawing's file.

 

Lots of ways to get the job done.

icelynnin
12-Amethyst
(To:d_graham)

Again- agreed, although a java solution means maintaining custom java code,

It also means interrogating the CAD files in Java, with APIs that are liable to change and having to rely on e.g. Creo Java toolkit?

It's a lot of work in the backend to set it up for very little gain.

The use case is weak (users seeing sheet count at a glance without opening Viz or DRW), so a simple OOTB way of doing it would have been tidy,

I don’t agree re: maintaining Java code.

I’ve been doing this since Windchill 6.2.6. and have never had a problem when I upgraded to a new release of Windchill.

 

Also, just for fun I write code to get the number of sheets for. Drawing file. I used only Java APIs, not windchill APIs. It worked great.

And it took about 5 minutes to write it. Not really a big deal.🤷‍♂️

 

Finally, Windchill has never had an OOTB way to read any content files and that’s what you’re looking for.

Announcements


Top Tags