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

Community Tip - Want the oppurtunity to discuss enhancements to PTC products? Join a working group! X

Setting "Autoselect Folder" as default location for new documents

Toby.Pettit
1-Newbie

Setting "Autoselect Folder" as default location for new documents

Hi All,

I have created a new soft type of a document which is for requests of various types. I have set up an OIR so that it is created in a certain folder. The only problem is the user has to select the "Autoselect Folder" option under the location when they are creating a document of this type. Is there any way to make it so that they do not have the option and it is automatically created in the folder I have specified?

Regards,

Toby

ACCEPTED SOLUTION

Accepted Solutions

You can manipulate in the OIR constraints:

- What a user sees

- What the system automatically does for folder assignment

See PTC's details in on-line help about OIRs

View solution in original post

10 REPLIES 10

You can manipulate in the OIR constraints:

- What a user sees

- What the system automatically does for folder assignment

See PTC's details in on-line help about OIRs

Hi Mike

Please could you point me in the right direction to find the online help you refer to?

If you have a link to the page that would be great as I am struggling to locate the information needed to manipulate the OIR constraint to set autoselect folder as the default

Many Thanks

Hi, Kelly,

I believe you can find the information you're looking for in the Windchill Help Center. For more information about OIRs, you could start with this topic: http://www.ptc.com/cs/help/windchill_hc/wc102_hc/index.jspx?id=ObjRulesChp_Intro&action=show.

For information about customizing attribute display (e.g., the UI behavior of the Location attribute), check the Attribute Customization topic: http://www.ptc.com/cs/help/windchill_hc/wc102_hc/index.jspxid=WCCG_UICust_PresentInfoUI_AttributeHandle&action=show

I hope you find this information helpful, and I'll welcome any feedback.

Regards,

Jane

Jane Zupfer
VP, Enterprise Products Publications
E -

PTC.com

Mat
13-Aquamarine
13-Aquamarine
(To:jzupfer)

Hi there,

I have exactly the same issue. Unfortunately those links do not work anymore.

Does anyone have a working link or some lines of code?

Cheers

Matthias

khawker
1-Newbie
(To:Mat)

Hi Matthias

Please see the below article which helped me to achieve this

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

Hope this helps. Let me know if you need anything further

Kind Regards

Kelly

You comment the below lines in OIR for that object type:

<!-- <AttrConstraint

id="folder.id"

algorithm="com.ptc.core.rule.server.impl.GatherAttributeConstraints"

ignore="false"

force="false"

final="false">

<Value algorithm="com.ptc.core.rule.server.impl.GetServerPreGeneratedValue">

</Value>

</AttrConstraint>

Add new Lines as below:

<AttrConstraint id="folder.id" algorithm="com.ptc.core.rule.server.impl.GatherAttributeConstraints">

<Value algorithm="com.ptc.core.rule.server.impl.GetServerPreGeneratedValue"/>

<Value algorithm="com.ptc.core.rule.server.impl.GetRendererConstraint">

<Arg>SelectGeneratedFolderByDefault</Arg>

</Value>

</AttrConstraint>

Make the chnages in Default folder path and add your required path as below:

<Arg>/Default/<Folder_Name></Arg>

I have done it for Promotion request and it worked without any issue.

Devidas,

I'd like to do exactly what you've done for the Promotion Request, however I do not know where or how to get to the file/setting where I'd add in the additional code. Could you describe how I get there?

Thanks,

Marc

BenLoosli
23-Emerald II
(To:mmontgomery)

You need to use the site/org admin utilities and edit the OIR rule for the setting you want to change.

So at site level>utilities>object initialization rules administration? Once there I have a long list of different OIR's, with the right-click choice to edit, download and a few others. It appears that the way to make a change is to 'download' the current rule, make changes in some kind of xml editor and then upload the modified rule by using the 'edit' right-click option?

Thanks,

Marc

BenLoosli
23-Emerald II
(To:mmontgomery)

That is correct.

The changes I made to the OIR rules pertain to which folder I store promotion request and change management files in. These are stored by year, so I have to make the change to my OIRs yearly.

Store your modified OIR files in a dedicated directory for 3 reasons: 1) you know which OIRs have been modified, 2) you don't have to download it again and 3) you can make future changes and just Edit-Browse to install.

Announcements


Top Tags