- Created by Waldemar Tribus, last modified on Feb 14, 2023
Challenge
The default ECTR installation provides many load options, like "Engineering View", "As Last Saved", "Production View", "Latest Released", and many more. Some of these load options may not be very helpful in some environments.
This How-to article describes what can be done in ECTR to prevent users from using certain load options.
Solution
There are several ways to achieve the goal.
Remove existing load options
Remove load option function
Anyway, the first common step is to remove the access to the load options combobox because in ECTR versions up to 5.2.7.0 there is no possibility to influence the content of this combobox by customizing.
The combobox is configured in the menu.guidef in the basis/config/ directory:
# System toolbar definition + om.custom.tool = fnc.back = fnc.window.manager = fnc.loadoption.change ...
... and should be changed in the menu.guidef in the customize/config/menu.guidef
The line "= fnc.loadoption.change" must be removed entirely:
# System toolbar definition + om.custom.tool = fnc.back = fnc.window.manager ...
This leads us to ECTR without any possibility to change current load option:
The current load options used by ECTR is controlled by preference plm.loadoptions.mode.
Now, if you just want that all user always use the load option "as saved" you can set this preference in customize/config/default.txt
plm.loadoptions.mode = asSaved
... and you are ready
Remove dedicated load options from combobox
With version 5.2.7.0 / 1.1.7.0 there is a new possibility planned to remove dedicated load options from the existing combobox.
Use load options in a different way
If you still want to be able to use some of the other load options, there are two ways to do it (you can also combine them):
a) Using options.xml
You can add following into customize/config/options.xml:
... <structure> <node card="root"> <node card="Load Options"/> </node> </structure> <card name="Load Options"> <option prefname="plm.loadoptions.mode" type="string" label="Load options" tooltip="choose load options"> <entry name="As saved" value="asSaved"/> <entry name="Engineering View (Highest version)" value="loadLatest"/> <entry name="Production View (today)" value="relToday"/> <entry name="Latest released" value="released"/> <entry name="My Latest, Other Released" value="user1"/> <entry name="As Saved, but replace obsolete" value="user2"/> <entry name="By Date" value="byDate"/> <entry name="By Change Number" value="byECM"/> </option> <option prefname="plm.loadoptions.ecm" type="string" label="Change Number" tooltip="enter ECN to use with 'By Change Number'"/> <option prefname="plm.loadoptions.date" type="string" label="Date (YYYYMMDD)" tooltip="enter Date to use with 'By Date' in format YYYYMMDD"/> </card> ...
This results in following panel in "Preferences" Dialog in ECTR:
Of course you can omit any unwanted load option from the above value list if you want to prevent it from being used by users.
With this setup, using options.xml, you have full control over which load options are made available to users.
b) Using load scenarios
For details read -> How to configure partial load scenarios
If users are loading assemblies with "As Saved" oder "Load Latest" in 99% of the cases and only in some special seldom cases they need to load "Latest Released", you can omit to edit options.xml and instead provide additional popup functions like "Open as Latest Released" in the context menu of the document.
First we need to define a load scenario which resolves the document structure using load option "released" by editing file applications/<YOUR CAD>/customize/config/load_scenarios.xml and adding new load scenario:
<document_load_scenario> <name>LatestReleased</name> <description>provide all files resolving by 'latest released'</description> <application_type>UGS</application_type> <bod_explosion> <explosion_scenario>CAD_LAOD</explosion_scenario> <explosion_rule> <latest_released/> </explosion_rule> </bod_explosion> </document_load_scenario>
Then you have to add the function 'fnc.doc.open.by.load.scenario(LatestReleased)' into popup menu of the document by editing applications/<YOUR CAD>/customize/config/menu.guidef:
+ om.popup.menu.DOC.NXM = ? DOC_GENERAL = fnc.doc.open.by.load.scenario(LatestReleased) ...
Then add dictionary key for this new menu entry:
fnc.doc.open.by.load.scenario(LatestReleased) = Open as Latest Released
There is now an entry in the context menu of the document that always resolves the BOD with the load option configured in the load scenario, regardless of the current value of the Load Options combo box or the current setting of the preference plm.loadoptions.mode:
Of course it is possible to combine all steps - removing the standard combobox, using options.xml and using load scenario to achieve best results in a specific customer environment.
- No labels