powered by CADENAS

Manual

Manual

1.7.2. Editing configuration files on file level

[Important] Important

Settings in the configuration files (CFG, DEF, etc.) should preferably be conducted in PARTadmin.

Editing in the configuration files should only be conducted by CADENAS (development, consulting).

For example, this can make sense for the new creation of files or setting special tags to control the display in PARTadmin.

For these cases we recommend the use of Windows Notepad or with higher requirements Notepad++. Please do not ever use PSPad, since errors with coding UTF8 may arise, which results in files being unreadable for PARTsolutions.

General syntax for tags

There are different types of tags for keys such as short description, value type definitions, activation/deactivation and control elements for the user interface. Short description and control elements can also be used for blocks.

All tags start with “#:”, followed by the keyword and end with a semicolon.

[Note] Note

TAGs should actually be used to improve usability, however, they are not technically required.

The following listing describes TAGs for placing help texts

  • HELP - Short description on keys or blocks

    #:HELP;

    In the dialog area Short description, information on keys or blocks is displayed (if provided).

    Example:

    #:HELP;Sketches are generated fixed and cannot be changed.

    At this place, the Short description is only created for the default language.

    [Note] Note
    • With V11 the translation management of config files has been consistently adapted to the usual standard. Translations can be deposited in def-files for all languages supported by PARTsolutions. Details on this can be found under Section 1.7.2.1, “Translation of "Short description" ”.

      The display in PARTadmin happens according to the set $CADENAS_LANGUAGE.

    • For compatibility reasons the language-dependent input option has been left. However, it is not used by the V11 ConfigEditor.

      #:HELP;default;Hello
      #:HELP;german;Hallo
      #:HELP;english;Hello
      #:HELP;spanish;Ola

    In order to insert a multiline short description, at the beginning of each extra line, set the hash mark (#).

    Example:

    #:HELP;This is the text of the first line.
    # This is the next line,
    # another line
    # etc.

    [Note] Note

    Lines which begin with a semicolon for example or without valid tag, are not displayed in PARTadmin.

  • CFGHELP - Short description on configuration file

    #:CFGHELP;

    [Note] Note

    Place this tag at the end of the configuration file (as with #:VISFGUICFG, if available).

    It doesn't matter which of these tags is the first. It is only important that no other blocks or keys will follow.

    Example:

    #:CFGHELP;Hello

    In order for multiline help texts to be added, at the beginning of each following line, set the hash mark (#).

    Example:

    #:CFGHELP;This is the text of the first line.
    #This is the next line,
    #another line,
    #etc.

    [Note] Note

    Lines which begin with a semicolon for example or without valid tag, are not displayed in PARTadmin.

    [Note] Note
    • The translation management happens analogously to the above described under CFGHELP.

The following listing describes TAGs for specifying value ranges

[Note] Note

If value ranges are not specified (so do not have a set "VALS_" tag), internally, "VALS_S" is supposed.

  • VALS_S - Alphanumerical key value

    • No specification of values

      #:VALS_S;

      If no values are specified, free input is possible.

    • Single value

      #:VALS_S;<String>

    • List of values

      #:VALS_S;<String list> 

      When listing several values use commas as separator.

      Example:

      #:VALS_S;"YES","NO"
      TOP_SEARCHPATH_SELECTION_CURRENT=YES

      If predefined values are given, in PARTadmin -> category Configuration files a list field is displayed.

  • VALS_SE - Alphanumerical key value with preset values + free input

    #:VALS_SE;

    Use this tag, if you want to preset certain values under PARTadmin -> category Configuration files and allow free input of values in addition.

    Example:

    VALS_SE;„one“,“two“,“three“

    Now the user is allowed to enter „four“ for example. With the tag "VALS_S" this is not possible.

  • VALS_N - Numerical key value

    • No declaration of values

      #:VALS_N;<numeric value>

      If no values are specified, under PARTadmin -> category Configuration files, free input is possible.

    • Single value

      #:VALS_N;<String>

    • List of values

      #:VALS_N;<list of numeric values>

      When listing several values use commas as separator.

      Example:

      #:VALS_N;0,1,2

      If predefined values are given, in PARTadmin -> category Configuration files a list field is displayed.

  • VALS_NE - Numerical key value with preset values + free input

    #:VALS_NE;

    Use this tag, if you want to preset certain values under PARTadmin -> category Configuration files and allow free input of values in addition.

    Example:

    VALS_NE;1,2,3

    The user is allowed to enter „4“ for example. With the tag "VALS_N" this is not possible.

  • VALS_L - List field selection with checkboxes

    #:VALS_L;

    Use this tag if you want to display a list field with checkboxes under PARTadmin -> category Configuration files.

    Example:

    #:VALS_L;1,2,3,4

    or

    #:VALS_L;a,b,c,d

  • VALS_LE - List field selection with checkboxes + free input

    #:VALS_LE;

    Use this tag if you want to display a list field with checkboxes under PARTadmin -> category Configuration files and enable free input in addition.

    Example:

    #:VALS_LE;a,b,c
    Key=a,b,c, extra_value

    The user may click into the input field and set an entry there.

    The user may click into the input field and set an entry there.

  • VALS_M - Mapped key values

    With this tag you can map a value or a range of values onto another value or another value range.

    Under PARTadmin -> category Configuration files, the mapped value is displayed. So the user sees a descriptive name, internally numerical values are used.

    • Mapped single value

      #:VALS_M;<value>;<mapped value>

    • Mapped value set

      #:VALS_M;<value>,<value>;<mapped value>,<mapped value>

    The mapping partners are separated by semicolon, single values by comma.

    Example:

    #:VALS_M;"0","1";"Load as part","Load as geometry" 
    keyname2=0

    Under PARTadmin -> category Configuration files a list field is displayed.

  • VALS_R - Value range declaration

    #:VALS_R;<from value> - <up to value>

    The limits of a value range are separated by a hyphen “-“.

    With this type, a listing of single values is not possible.

    Example:

    #:VALS_R;0-10
    DEBUGMODE=

    When entering values under PARTadmin -> category Configuration files these are checked. Values out of the defined range are not permitted.

  • VALS_C - Correct display of code phrases

    #:VALS_C;<code phrase>

    With the help of this tag you can use code phrases in a list field in PARTadmin.

    When using several lines as of the second line prefix a hash mark "#".

    Then the different options are displayed in a list field.

    Example:

    #:VALS_C;0
    #1
    #any_vb_expression
    CADOPTION=

The following listing describes TAGs for general control

  • INACTIVE - Deactivation of keys

    #:INACTIVE;<name of key>

    If a key currently shall not be evaluated by applications, use this tag.

    Prefix the string #:INACTIVE; to the key.

    Example:

    #:INACTIVE;ShowInTable =no

    If a key is tagged in this way, then it is displayed in PARTadmin -> category Configuration files as "inactive" . Furthermore the command Activate key or Deactivate key is displayed in the context menu, so that you can change the status anytime.

  • VISFGUI - Control visibility of keys and blocks

    #:VISFGUI;<bool>

    Use this tag to control the visibility of keys or blocks in the user interface of PARTadmin:

    Place this tag in a line before the desired block or key.

    • Visible (default)

      #:VISFGUI;1

      [Note] Note

      If the default value shall be used you don't have to set the tag explicitly.

    • Not visible

      #:VISFGUI;0

  • VISFGUICFG - Control visibility of configuration files

    #:VISFGUICFG;<bool>

    Use this tag to control the visibility of a configuration file in PARTadmin:

    [Note] Note

    Place this tag at the end of the configuration file (as with #:VISFGUICFG, if available).

    It doesn't matter which of these tags is the first. It is only important that no other blocks or keys will follow.

    • Visible (default)

      #:VISFGUICFG;1

      [Note] Note

      If the default value shall be used you don't have to set the tag explicitly.

    • Not visible

      #:VISFGUICFG;0

  • SIMPLE - Mark important keys for filtering

    #:SIMPLE;<bool>

    Use this tag in order to mark keys which have to be adjusted in any case to ensure an orderly functioning in PARTsolutions.

    In PARTadmin, keys tagged in this way can be filtered.

    Example:

    #:SIMPLE;1
    poolpath(isCreaOptNotSet)=?_FORMAT_0("$CADENAS_DATA/pool/solidedge/<PREFIXLIST(/)>")....

    Place the tag in a line before the desired key.

    • Standard sorting in PARTadmin (Default)

      #:SIMPLE;0

      [Note] Note

      If the default value shall be used you don't have to set the tag explicitly.

    • Filtering with option Only important keys enabled in PARTadmin

      #:SIMPLE;1

Some examples

#:VALS_S 
#:HELP;CheckOut Folder for Native Parts 
#:SIMPLE;1 
NativeCheckoutTargetFolder=?Application.ResolveEnv("%CADENAS_DATA%\\pool\\catia")

#:VALS_S 
#:HELP;Submenu - Tools - Activate the command that should be loaded at startup 
 and set the value on "Yes". 
If a key is disabled the code and command will not be available in CATIA. See manual.
#:INACTIVE;COMMAND_SHOW_PSOLNCScan=no

#:VALS_S 
#:VISFGUI;0 
#:INACTIVE;MetaObjectVersion=""

Older tags

There are still older tags in the config files. For reasons of version management these comments stay in the config. However, please do not use them for new tagging anymore.

Older tags are:

  • #:NAME;

  • #:LNAME;

  • #:DESC;

  • #:TOOLTIP;

  • #:SAMPLE;

Special tags under $CADENAS_DEFAULTUSER

TAG Description

#!

  • The tag corresponds to the context menu command Overwrite always under PARTadmin -> Configuration files on key level: Yellow background color

    The key value in $CADENAS_USER is overwritten again upon each load of the application.

  • The tag corresponds to the context menu command Overwrite under PARTadmin -> Configuration files on block level.

    Same blocks from $CADENAS_DEFAULTUSER and $CADENAS_USER are completely overwritten.

#-

  • The tag corresponds to the context menu command Delete under PARTadmin -> Configuration files on key level: Red background color

#~

  • The tag corresponds to the context menu command Do not merge under PARTadmin -> Configuration files on block level.

    Same blocks from $CADENAS_DEFAULTUSER and $CADENAS_USER are not merged.