Page tree
Skip to end of metadata
Go to start of metadata

Purpose / Use Case

For non-CAD you like to have different functions for the double-click on a DIR. Not open the CAD system but open an alternative file from the DIR.

Step-by-Step instructions

See also in the Operation guide chapter "5.1 Roles in SAP Engineering Control Center", or search for "PLM_ROLE".

saplogon.txt
     sap.logon.cad_group_id1   = CADUSER
     sap.logon.cad_group_desc1 = CAD User
     sap.logon.cad_group_id2   = NONCADUSER
     sap.logon.cad_group_desc2 = Non CAD User


Create files plm_setenv_<ROLE>.bat inside <ECTR_INST_DIR>\customize\config\ for all desired roles

e.g.

content of plm_setenv_CADUSER.bat:
SET FNC_OPEN_VIEW=fnc.doc.open.fast.view
SET FNC_OPEN_EDIT=fnc.doc.open.fast.edit
content of plm_setenv_NONCADUSER.bat:
SET FNC_OPEN_VIEW=fnc.doc.open.any(view,pdf)
SET FNC_OPEN_EDIT=fnc.doc.open.any(edit,pdf)

e.g change the desired menu definition and use environment variables  FNC_OPEN_VIEW and FNC_OPEN_EDIT as placeholder:

 

menu.guidef or menu_macros.txt
? DOC_GENERAL
                                     = fnc.doc.open.fast.view
                                     = fnc.doc.open.fast.edit
 
change to
? DOC_GENERAL
                                     = @FNC_OPEN_VIEW@
                                     = @FNC_OPEN_EDIT@
 
add dictionary entries for fnc.doc.open.any(view,pdf) and fnc.doc.open.any(edit,pdf) in customize\dictionary\en\customer.txt:
fnc.doc.open.any(view,pdf)=view PDF
fnc.doc.open.any(edit,pdf)=edit PDF

 

Result

If the SAP User has role "CADUSER" he will open the document in CAD.

 

If the SAP User has the role "NOCADUSER" he will try to open pdf instead.

Use Case System font size

You want to adjust the font size of the ECTR. Now you want an individual setting for each user.

  • Is it possible to read out a parameter from the SAP user?
  • Or show a pull-down selection in the ECTR login dialog?

Solution with user parameter

ECTR already provides the user parameters as environment variables and a pref can reference an environment variable.
Example:

system.font.defaultFont = @SAP.USER.PARAMETER.<your_parameter>@

Solution with ECTR login dialog

You have to set up the "cad groups" combo box instead of going to SAP roles.

saplogon.txt
     sap.logon.cad_group_id1   = BIG_FONT
     sap.logon.cad_group_desc1 = Big font
     sap.logon.cad_group_id2   = NORMAL_FONT
     sap.logon.cad_group_desc2 = Normal Font


Create files plm_setenv_<ROLE>.bat inside <ECTR_INST_DIR>\customize\config\ for all desired roles

e.g.

content of plm_setenv_BIG_FONT.bat:
SET ECTR_FONT=SansSerif;   PLAIN; 16
content of plm_setenv_NORMAL_FONT.bat:
SET ECTR_FONT=SansSerif;   PLAIN; 12

e.g change the desired menu definition and use environment variables  FNC_OPEN_VIEW and FNC_OPEN_EDIT as placeholder:

 

default.txt
# ECTR default font
# Set the default font used in ECTR
# When changing this it has to be checked if the font supports the local charset

      system.font.defaultFont                    = @ECTR_FONT@