• No results found

Initialization files

In document Tekla Structure System_Tutorial (Page 79-85)

Initialization files are used to launch Tekla Structures. They can contain many variables that you can use to configure Tekla Structures for different standards and your own style of working.

Tekla Structures automatically creates the necessary initialization files during installation.The number of initialization files it creates depends on how many country-specific environments you choose to install.

We recommend that you make all your customizations in the user.ini file, which is located in the ..\TeklaStructures\ 14.0\nt\bin folder. This way the customizations are kept when you install the next version of Tekla Structures.

Topics About variables (p. 80) Structure (p. 81)

Creating shortcuts (p. 83) See also Appendix C, Variables (p. 285)

About variables

Tekla Structures contains two kinds of variables, user variables and system variables. User variables User variables set your personal preferences, for example the appearance of the Tekla Structures

window. Tekla Structures saves user variable settings in the

options_<your_username>.ini file, located in the TeklaStructures\

14.0\nt\bin folder.

System variables options.ini contains the settings for system variables. It is located in the current model folder. To share your settings with other people, copy options.ini to the system, project or firm folders.

Setting variables

Use variables to configure Tekla Structures to suit the way you work, or to comply with specific project requirements or industry standards. You can set variables by:

Using the Advanced Options dialog box (p. 80) OR

Editing the user.ini file (p. 80)

We recommend that you only use one of these methods to set variables. The variable settings in the Advanced options dialog box override those in the initialization files.

Using the Advanced Options dialog box

To set a variable using the Advanced Options dialog box:

1. Click Tools > Options > Advanced Options... to open the Advanced Options dialog box.

2. Browse the categories to find the variable you want to set.

3. Set the variable, then click Apply or OK in the Advanced Options dialog box.

Editing the user.ini file

To set a variable in the user.ini file:

1. Locate the variable in the ..\TeklaStructures\ 14.0\nt\bin\user.ini file.

Check that it is set and has the value you want to use.

If required, Tekla Structures prompts you to restart Tekla Structures when you change a variable setting,

If required, Tekla Structures prompts you to restart Tekla Structures when you change a variable setting.

2. Right-click the ..\TeklaStructures\ 14.0\nt\bin\user.ini file in Windows Explorer and click Open with.... Select a standard text editor from the list of available programs.

3. On a new line, type set, then the name of the variable followed by its value in a single line.

Tekla Structures only reads lines in the initialization file that start with set, for example, set XS_DIR=C:\TeklaStructures\ 14.0.

4. Save user.ini.

5. Restart Tekla Structures to activate the variable.

Different variables use different switches in Tekla Structures. To check which switch a variable uses, check Appendix C, Variables (p. 285).

Disabling variables in an initialization file

To disable a variable, add it to the user.ini file without a value. Do not add any spaces or characters after the equals sign. See the example below:

set XS_SINGLE_CLOSE_DIMENSIONS=

Structure

This section describes the location and folder and hierarchical structure of different initialization files.

You must restart Tekla Structures after changing the initialization file for the changes to take effect.

Switc

h Value Example

TRUE FALSE

set XS_DISABLE_WELD_PREP_SOLID=TRUE set

XS_DIMENSION_DIRECTION_REVERSED=FALSE 1 On set XS_SINGLE_CLOSE_DIMENSIONS=1 0 Off set XS_SINGLE_USE_WORKING_POINTS=0

string set

XS_USER_DEFINED_BOLT_SYMBOL_TABLE=bolt_

symbol_table.txt

number set XS_DEFAULT_FONT_SIZE=12

In previous versions you could disable a variable by adding "rem" before it. This does not disable the variable, if the same variable is set in the other initialization files.

rem set XS_AUTOSAVE_DIRECTORY=%XS_RUNPATH%\autosave

teklastructures.in i

The file teklastructures.ini in the bin folder starts Tekla Structures.

env_global_defau lt.ini

The file env_global_default.ini is used as a default for all environments. New options can be added in this file until they are localized and specified differently in environment-specific initialization files.

env_<your_envir onment>.ini

The env_<your_environment>.ini files in the environments subfolders contain all the variables that have environment-specific settings.

user.ini The user.ini file is where you save your personal settings. The variables in user.ini override those in other ini files. For example, if you have set the same variable in an .ini file in a file in environments subfolder and the user.ini file, Tekla Structures uses the value in the user.ini file.

Default settings teklastructures.ini and the .ini files in the environmentssub folders contain default settings. Tekla Structures creates them automatically during installation. We recommend that you do not modify these files.

teklastructures.ini in the bin folder calls the other initializa-tion files in the environments subfolders.

Add your own settings to user.ini in the bin folder.

See Variables (p. 285) for details of all variables.

1. Program settings: .../nt/bin/TeklaStructures.ini

2. Language-specific settings: .../nt/bin/lang_<CurrentLanguage>.ini 3. Environment and other settings: all .ini files given as program startup parameters (in the

given order)

Creating customized initialization files

You can create customer-specific initialization files that include custom settings particular to each customer, a company and/or a single project. You can also create customized initialization files for multi-user mode as needed. To do this:

1. Open the user.ini file located in the folder..\TeklaStructures\

14.0\nt\bin using any standard text editor. Save the file with the required name, such as customer.inior project.ini.

2. Edit the file by adding the required customer settings.

3. Save the modified initialization file.

Including other initialization files

Initialization files can include or call other initialization files. You can use this functionality to create shortcuts for different purposes, for example to have different setup files depending on the client you are working for in a project such as fabricators.

Below is an example of a project initialization file that calls other initialization files.

MyProject.ini:

// The project is based on the default US imperial settings call c:\TeklaStructures\13.1\environments\usimp\env_usimp.ini // ..but our company policy requires these changes

call c:\CompanySettings\OurPolicy.ini // ..and the fabricator requires something call c:\Fabricators\Fabricator1.ini

// ..and then we let users to make some changes (bg color etc.) call c:\Users\user_%USERNAME%.ini

The project shortcut for MyProject:

C:\TeklaStructures\13.1\nt\bin\TeklaStructures.exe -i

\\MyServer\MyProject\MyProject.ini

\\MyServer\MyProject\MyModel\MyModel.db1

Creating shortcuts

Shortcuts are used to start teklastructures.exe with defined initializations. The Tekla Structures installation automatically creates shortcuts for the selected environments.

To create a project-specific shortcut:

1. Make a copy of the default shortcut. In the Windows Start menu, go to All Programs >

Tekla Structures 14.0 > Tekla Structures 14.0 <your_environment> and right-click.

2. Select Copy from the pop-up menu.

3. Paste the shortcut to your desktop.

The variable settings in the user.bat file override those in the batch files contained in the environment and language folders.

4. Select the shortcut and right-click.

5. Select Properties... from the pop-up menu.

6. Modify the Target of the shortcut by adding the required project initializations to it.

You can use the following parameters in shortcuts:

-i InitializationFile: Initialization file to be read during startup, for example: -i

\\MyServer\MyProject\Project1.ini. You can repeat this parameter as many times as you need.

ModelToBeOpened: Full path to the model to be opened automatically.

The maximum length of a shortcut is 256 characters. If you have prob-lems with this, you can include other necessary initialization files from your project initialization file instead of adding them to the shortcut. For more information see Including other initialization files (p. 83).

In document Tekla Structure System_Tutorial (Page 79-85)