Properties of the objects.inp file

Tekla Structures
2023
Tekla Structures

Properties of the objects.inp file

User-defined attribute definitions in the objects.inp file follow this structure.

For general information about modifying the definitions, such as file locations and reading order, see Define and update user-defined attributes (UDAs).

This example shows the main properties of objects.inp:

attribute("MY_INFO_1", "My Info 1", string, "%s", no, none, "0.0", "0.0")
{
	value ("", 0)
}
picture("image_name", 8, 2, 260, 25)

General properties

Property In the example Description

attribute or unique_attribute

attribute

Specifies whether the attribute is a regular attribute or a non-copyable attribute.

attribute is a regular attribute, which is copied with other part properties.

unique_attribute is a non-copyable attribute. The value of the attribute is never copied to another part. For example, part checking status attributes usually cannot be copied.

attribute_name

MY_INFO_1

The attribute name is used to find the attribute value.

Ensure that Tekla Structures does not already use the attribute name that you use. Consider using a prefix that ensures the name is unique, such as your initials, or an abbreviation of your company name.

The attribute name is case-sensitive. Do not use spaces or reserved characters in attribute names. The maximum length of the name can be 19 characters.

To include the attribute in a report or template, add the name of the attribute to your layout in the Template Editor. When you run a report or create a drawing, Tekla Structures shows the current value of the attribute.

label_text

My Info 1

A label that Tekla Structures shows in the dialog box.

Some default attributes have prompts like j_comment, meaning that the prompt comes from the joints.ail message file.

value_type

string

The type of value that the field can contain:

  • integer: whole numbers

  • float: numbers that include a decimal point

  • string: text

    The maximum string length is 79 characters.

  • string_not_modifiable: Text whose modification is prevented. A field with the string_not_modifiable property is always shown as dimmed and it cannot be switched on or off. The value in the field is not saved when clicking the Apply button or modified when clicking the Modify button.

  • option: lists

  • date: date with a small calendar

  • date_time_min: date and time in hours and minutes [12:00] with a small calendar

  • date_time_sec: date and time in hours, minutes, and seconds [12:00:00] with a small calendar

If you need to change the value_type, create a new user-defined attribute instead of modifying the current one in the objects.inp file. For example, if you change the value_type from string to option, the value cannot be changed for parts that have the property specified with the old value type, and the value is shown incorrectly in reports or when you inquire objects.

When the advanced option XS_DIAGNOZE_AND_REPAIR_WRONG_UDA_TYPE is set to TRUE, you can use Diagnose & repair > Diagnose and change attribute definitions to detect and repair the incorrect UDA value types by reverting the value types to the default values. The command checks that the UDA value types, such as string or option, defined in the objects.inp file match their values defined in environment.db. A mismatch can happen if you change the value types after the UDA values have been assigned.

field_format

%s

Definition of the field format in the dialog box

  • %s for strings

  • %d for numbers

special_flag

no

no or yes

For parts: consider in numbering

For drawings: show the attribute value in Document manager

For other elements: no effect

check_switch

none

none

This option is not used.

attribute_value_max

0.0

0.0

This option is not used.

attribute_value_min

0.0

0.0

This option is not used.

Picture properties

Property In the example Description

picture

picture

picture is used for adding images in user-defined attributes dialog boxes.

image name image_name The name of the image
width 2 The width reserved for the image
height 8 The height reserved for the image
horizontal offset 260 The horizontal distance of the left edge of the image from the left edge of the dialog box
vertical offset 25 The vertical distance of the top edge of the image from the top edge of the dialog box counted from the lower edge of the tab section

You can also hide or dim user-defined attributes. For more information, see How to hide and grey out user-defined attributes.

Var det här användbart?
Föregående
Nästa