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

Community Tip - You can change your system assigned username to something more personal in your community settings. X

Data utility to force name to uppercase

SimonLucas
12-Amethyst

Data utility to force name to uppercase

Hi,

we would like to enforce all names being uppercase, both on creation and during rename.

Had the idea of creating a custom data utility to drive this which could be fired on a rename. Is it also possible to reference a data utility in an OIR or would we need to check for check in and fire the utility then?

Cheers

5 REPLIES 5
LoriSood
22-Sapphire III
(To:SimonLucas)

What about putting an Uppercase constraint on the attribute?

5-21-2015 5-08-11 PM.png

The constraint types are mentioned here:

http://www.ptc.com/cs/help/windchill_hc/wc101_hc/index.jspx?id=TypeMgrAttrConstraintRuleRef&action=show

HI,

that will fix the uppercase part, but also now looking at doing some sanity checking such as replacing underscores with spaces and possible some escape characters so that you can force certain characters to lower case such as when specifying a bolt size eg M10x35.

Currently looking into either using a validator or a listener as also need to be able to check on rename.

LoriSood
22-Sapphire III
(To:SimonLucas)

I think a validator could be used here. The following article provides an example of how to check name and number in the rename wizard. You should be able to modify this to suit your purposes:

https://support.ptc.com/appserver/cs/view/solution.jsp?n=CS119050

Does anyone know why this solution does not apply to CAD Documents?

IMPORTANT NOTE: This does not apply to the CAD Documents (EPMDocument) rename action

LoriSood
22-Sapphire III
(To:MarkBohannon)

Mark,

A different wizard/set of code is used to rename CAD Documents, which is why the code in the article will not work for that type.

The supported approach for CAD Documents is to use a listener. See https://support.ptc.com/appserver/cs/view/solution.jsp?n=CS121491.

Announcements


Top Tags