Вы находитесь на странице: 1из 13

Tekla Open API

Release Notes

Tekla Structures 17.0 SR1


April 2011
Copyright 2011 Tekla Corporation

2011 Tekla Corporation and its licensors. All rights reserved.


This Software Manual has been developed for use with the referenced Software. Use of the Software, and use of this Software
Manual are governed by a License Agreement. Among other provisions, the License Agreement sets certain warranties for the
Software and this Manual, disclaims other warranties, limits recoverable damages, defines permitted uses of the Software, and
determines whether you are an authorized user of the Software. Please refer to the License Agreement for important obligations and
applicable limitations and restrictions on your rights.
In addition, this Software Manual is protected by copyright law and by international treaties. Unauthorized reproduction, display,
modification, or distribution of this Manual, or any portion of it, may result in severe civil and criminal penalties, and will be
prosecuted to the full extent permitted by law.
Tekla is a trademark of Tekla Corporation. Tekla is a registered trademark of Tekla Corporation in the European Union, the United
States, and in several other countries. Tekla Structures, Xcity, Xengineer, Xpipe, Xroad, Xstreet, Xpower, Xsteel, and Xstreet are
either registered trademarks or trademarks of Tekla Corporation in the European Union, the United States, and/or other countries.
Other product and company names mentioned in this Manual are or may be trademarks of their respective owners. By referring to a
third-party product or brand, Tekla does not intend to suggest an affiliation with or endorsement by such third party and disclaims any
such affiliation or endorsement, except where otherwise expressly stated.
Portions of this software:
D-Cubed 2D DCM 2008 Siemens Product Lifecycle Management Software III (GB) Ltd. All rights reserved.
EPM toolkit 1995-2004 EPM Technology a.s., Oslo, Norway. All rights reserved.
XML parser 1999 The Apache Software Foundation. All rights reserved.
Project Data Control Library 2006 - 2007 DlhSoft. All rights reserved.
DWGdirect, DGNdirect and OpenDWG Toolkit/Viewkit libraries 1998-2005 Open Design Alliance. All rights reserved.
FLEXnet Copyright 2006 Acresso Software Inc. All Rights Reserved. This product contains proprietary and confidential technology
provided by and owned byAcresso Software Inc. Of Chicago, Illinois, USA. Any use, copying, publication, distribution, display,
modification, or transmission of such technology in whole or in part in any form or by any means without the prior express written
permission of Acresso Software Inc. is strictly prohibited. Except where expressly provided by Acresso Software Inc. in writing,
possession of this technology shall not be construed to confer any license or rights under any of Acresso Softwares intellectual
property rights, whether by estoppel, implication, or otherwise.
Elements of the software described in this Manual may be the subject of pending patent applications in the European Union and/or
other countries.

Contents
1

Introduction ................................................................................................................ 1

Fixes and Improvements in 17.0 SR1 ....................................................................... 1


2.1
2.2
2.3
2.4

Tekla.Structures.Model 17.0.0.0 Assembly ............................................................................... 1


Tekla.Structures.Drawing 17.0.0.0 Assembly ............................................................................ 2
Tekla.Structures.Dialog 17.0.0.0 Assembly ............................................................................... 2
Tekla.Structures.Catalogs 17.0.0.0 Assembly ........................................................................... 2

New or Changed Functionality in 17.0 ...................................................................... 3


3.1
3.2
3.3
3.4
3.5
3.6
3.7
3.8
3.9
3.10

Model API content frozen .......................................................................................................... 3


.NET Framework 4.0 and other general changes ...................................................................... 4
Tekla.Structures 17.0.0.0 Assembly .......................................................................................... 4
Tekla.Structures.Plugins 17.0.0.0 Assembly ............................................................................. 4
Tekla.Structures.Model 17.0.0.0 Assembly ............................................................................... 5
Tekla.Structures.Drawing 17.0.0.0 Assembly ............................................................................ 8
Tekla.Structures.Datatypes 17.0.0.0 Assembly ......................................................................... 9
Tekla.Structures.Dialog 17.0.0.0 Assembly ............................................................................... 9
Tekla.Structures.Catalogs 17.0.0.0 Assembly ........................................................................... 9
Tekla.Structures.Analysis 17.0.0.0 Assembly .......................................................................... 10

TEKLA OPEN API RELEASE NOTES


Contents

Introduction

This document describes the fixes and improvements in the Open API, released in
Tekla Structures version 17.0 SR1. The new or changed functionality of the Open API
in Tekla Structures 17.0 is also included in Chapter 3.
Reference manual

Please refer to the API reference manual TeklaOpenAPI_Reference.chm for more


information.

Fixes and Improvements


in 17.0 SR1

This chapter describes the Open API fixes released with Tekla Structures 17.0 SR1.
The assembly version numbers remain unchanged:

AssemblyVersion: 17.0.0.0

AssemblyFileVersion: 17.0.0.0

2.1 Tekla.Structures.Model 17.0.0.0


Assembly
The handling of looping hierarchic definitions has been improved.
The TransformationPlane(Point Origo, Vector Xvector, Vector Yvector) constructor
doesnt change the two vectors given as parameters anymore.
TEKLA OPEN API RELEASE NOTES
Introduction

It is now possible to insert rebars with empty () names.


The number of transferred phases has been increased from 100 to 10 000.
When modifying an assembly, if the prefix and start number are the same as the main
parts prefix and start number, then the main parts numbering series does not get
locked anymore.

2.2 Tekla.Structures.Drawing 17.0.0.0


Assembly
Loading and modifying a view by loading the view attributes from the attribute file
were showing all the parts inside the area instead of filtering the parts by assembly,
cast unit or part. This has now been fixed.

2.3 Tekla.Structures.Dialog 17.0.0.0


Assembly
When plug-in or application attributes are saved and the "attributes" folder doesn't
exist, the base class PluginFormBase now creates it automatically. Also the
FormBase.SaveValues method is now safer because of a new catch block.
If a plug-in dialog and the Tekla Structures main window were both minimized, the
restoring of the main window froze Tekla Structures. This has been fixed.
The MainWindow class has been fixed to work with applications with new dialog
handling.
With .NET plug-ins with Forms dialogs, modify didnt work the second time if nested
plug-ins were used and LoadAttributesFromFile() was used to set the attributes. This
has been fixed.

2.4 Tekla.Structures.Catalogs 17.0.0.0


Assembly
There have been fixes in the RebarItemEnumerator class related to the clearing and
getting of the rebar items.

TEKLA OPEN API RELEASE NOTES


Fixes and Improvements in 17.0 SR1

New or Changed
Functionality in 17.0

This chapter describes the new or changed functionality in Tekla Structures 17.0.

3.1 Model API content frozen


Goal

The goal of the API content freeze is that modeling applications and plug-ins will then
work with future Tekla Structures versions without recompilation. The freezing is valid
until compatibility is broken due to a mandatory reason such as upgrading the API
assemblies to a newer .NET framework version.

The scope

The API content freeze concerns the following assemblies in the API:

Tekla.Structures.dll

Tekla.Structures.Model.dll

Tekls.Structures.Plugins.dll

Tekla.Structures.Dialog.dll

Tekla.Structures.Datatype.dll

What does it mean in


practice?

In practice, the freezing means that the public properties and methods of public
classes in 17.0 will not change with future versions in the above assemblies.
However, new classes or new properties or methods to existing classes can still be
added.

How is compatibility
achieved?

Compatibility will be handled using configuration files. For plug-ins this happens
automatically, but for applications the bindingRedirect element must be added to the
application configuration file (app.config). For example:
<dependentAssembly>
<assemblyIdentity name="Tekla.Structures
publicKeyToken="2f04dbe497b71114 culture="neutral" />
<bindingRedirect oldVersion=17.0.0.0 newVersion=18.0.0.0"/>
</dependentAssembly>

TEKLA OPEN API RELEASE NOTES


New or Changed Functionality in 17.0

3.2 .NET Framework 4.0 and other


general changes
.NET Framework 4.0

Tekla Open API now uses the .NET Framework version 4.0.

API architecture
clarified

Obsolete methods and constructors (listed later in this document) have been
removed.
Dependencies between assemblies have been reduced. Now it is easier to implement
a drawing application without using the Tekla.Structures.Model assembly.
The GetAdvancedOption method has been moved from the Tekla.Structures.Model
namespace to the Tekla.Structures namespace. A new TeklaStructuresSettings class
provides methods to inquire advanced options.
The GetSelectedObjects method has been moved from the Tekla.Structures.Model
namespace to the Tekla.Structures.Model.UI namespace. The method can now be
found from the ModelObjectSelector class.
The ModuleManager class has been moved from the Tekla.Structures.Model
namespace to the Tekla.Structures namespace.
The GetCurrentProgramVersion method has been moved from the Model class in the
Tekla.Structures.Model assembly to the TeklaStructuresInfo class in the
Tekla.Structures assembly.
The AnalysisResult class has been moved from the Model assembly to the Analysis
assembly.

Remoting exception
thrown

A RemotingException is now thrown if the remote connection to Tekla Structures fails.

Logging

The log file dotlog.txt doesnt exist anymore in the \nt\bin folder. Loaded plug-ins
and their assemblies are now written to the Tekla Structures log file.

3.3 Tekla.Structures 17.0.0.0 Assembly


GetAngleBetween
method improved

Previously, the GetAngleBetween method in the Vector class worked only with angles
bigger than 2.56 degrees; now the tolerance is 0.8 degrees.

3.4 Tekla.Structures.Plugins 17.0.0.0


Assembly
UDAs can be added to
a plug-in

The Identifier property has been added to the PluginBase and ConnectionBase
classes. The property can be used to store custom properties as UDAs to a plug-in
inside the Run method.
TEKLA OPEN API RELEASE NOTES
New or Changed Functionality in 17.0

Plug-in symbol added

The symbol is now drawn and visible by default in all model plug-ins with Forms
dialogs. For plug-ins with inp dialog definition the symbol visibility can be defined in
the inp file by adding the line:
draw(1, 50.0, 50.0, 0.0, 0.0)

Max 10 input
definitions

Maximum number (10) checking has been added for input definitions in the
<List>InputDefinition for PluginBase components.

3.5 Tekla.Structures.Model 17.0.0.0


Assembly
Fields changed to
properties

All fields of the Model assembly classes have been changed to properties.

Obsolete constructor
removed

The Model constructor with the bool parameter SkipChannelCreation has now been
removed (the constructor was marked as obsolete earlier). Use Model() instead.

Obsolete methods
removed

The Open method, which was earlier marked as obsolete, has now been removed.
Use methods in Tekla.Structures.Model.Operations instead.
The obsolete method SaveAsWebModel has been removed. Use methods in
Tekla.Structures.Model.Operations instead.

PickFace added

The PickFace method returns a PickInput instance that contains the face points and
the object. Please see the code example in the PickInput class documentation.

ComponentInput
implements
ICollection

The ComponentInput class now implements the ICollection interface. The InputItem
class can be used with the PickInput class in face picking. For example:
ComponentInput ComponentSel = C.GetComponentInput();
IEnumerator Enumerator = ComponentSel.GetEnumerator();
while (Enumerator.MoveNext())
{
InputItem ObjectInput = Enumerator.Current as InputItem;
if (ObjectInput.GetInputType() ==
InputItem.InputTypeEnum.INPUT_1_OBJECT)
{
Beam BeamInput = ObjectInput.GetData() as Beam;
}
}

The maximum number of InputItems in ComponentInput is 10.


Class for edge
chamfers added

The EdgeChamfer class has been added. With the new class you can define how the
part edge is chamfered. For example:

TEKLA OPEN API RELEASE NOTES


New or Changed Functionality in 17.0

Point Point = new Point(0, 0, 0);


Point Point2 = new Point(1000, 0, 0);
Beam Beam = new Beam();
Beam.StartPoint = Point;
Beam.EndPoint = Point2;
Beam.Profile.ProfileString = "400*400";
Beam.Finish = "PAINT";
Beam.Insert();
EdgeChamfer EdgeChamfer = new EdgeChamfer(new Point(0, -100, 0), new
Point(0, 200, 0));
EdgeChamfer.FirstChamferEndType =
EdgeChamfer.ChamferEndTypeEnum.BEVELLED;
EdgeChamfer.FirstBevelDimension = 50;
EdgeChamfer.Chamfer.X = 20;
EdgeChamfer.Chamfer.Y = 20;
EdgeChamfer.Father = Beam;
EdgeChamfer.Insert();
Insert, delete and get
phases

The Insert and Delete methods have been added to the Phase class.
The GetPhases method was added to the Model class. The method returns a
PhaseCollection instance.

Display prompt

Access to the Tekla Structures message panel is now possible by using the
DisplayPrompt method in the Operation class.

Checking numbering

The IsNumberingUpToDate method has been added to the Operation class.

Return value of rebar


group splitting
changed

The Split method for rebar groups, located in the Operation class, splits the rebar
group and creates a new one in the given position. Earlier the method returned a
boolean value, but now the method returns the created RebarGroup instance if the
splitting was successful.

Fetching objects by
type

Now it is possible to fetch objects by their type by using the GetAllObjectsWithType


method in the ModelObjectSelector class. For example:
ModelObjectEnumerator myEnum =
myModel.GetModelObjectSelector().GetAllObjectsWithType(new
System.Type[] { typeof(Part) , typeof(BoltGroup) });

Exceptions improved

The Material and Profile properties need to have some information before
inserting/modifying a Part, otherwise an ArgumentException is thrown.
An ArgumentNullException has been added to HierarchicObject, Task and
HierarchicDefinition constructors.

Stitched weld

Now it is possible to choose the weld technique: stitched weld or not stitched weld.
"Intermittent" properties for above and below lines have been removed. Now the weld
is considered to be intermittent if the pitch value is greater than zero.

TEKLA OPEN API RELEASE NOTES


New or Changed Functionality in 17.0

Question and warning


dialogs removed

The modal dialog "Assembly structure includes weldings or bolts. Delete weldings
and bolts?" is not shown anymore when trying to remove or add a part to an
assembly. The methods fail if there are workshop welds/bolts.
Modal warning dialogs do not appear anymore when combining parts; the warnings
are ignored.

Class property added


to components

The Class property has been added to the Connection, Detail and Seam classes.

Seams without
secondaries

Seams without any secondaries are now supported.

Getting objects by
bounding box
changed

The GetObjectsByBoundingBox method in the ModelObjectSelector class has been


changed to work in the current work plane. Earlier, the bounding box axis stayed
oriented to the global plane, which caused the method to grab several more objects
when trying to set the bounding box to a skew plane.

ProjectInfo improved

The ProjectInfo class now contains the Info1 and Info2 properties which appear in the
Project Properties dialog in Tekla Structures.

Clip plane support


added

A new class ClipPlane has been added. The class contains the following methods:

Insert

- Creates a new clip plane to the view.

Delete

- Deletes a clip plane from the view.

Modify

- Modifies the clip plane position in the view.

The GetClipPlanes method for getting all the clip planes from the view has been
added to the View class. A new class ClipPlaneCollection has also been added.
ModelHistory class
changed

The ModelHistory class now supports multiuser models. The class has also been
changed to be a static class.
The method names have been changed to follow the naming convention in the
ModelObjectSelector: GetAllModifiedAfterModStamp -> GetModifiedObjects.
The new method names are:
GetModifiedObjects(ModificationStamp ModStamp)
GetModifiedObjectsWithType(ModificationStamp ModStamp,
ModelObject.ModelObjectEnum Enum)
Methods to retrieve deleted objects have been added:
GetDeletedObjects(ModificationStamp ModStamp)
GetDeletedObjectsWithType(ModificationStamp ModStamp,
ModelObject.ModelObjectEnum Enum)

TEKLA OPEN API RELEASE NOTES


New or Changed Functionality in 17.0

Beam.Type added

The Type property has been added to the Beam class for identifying the beam types
column, pad footing and strip footing in the selection and creation of beams. In the
creation, the Type must be initialized in the constructor.

Other fixes

Beams that use the plate profile and are created with components can now be
selected correctly.
It is now possible to change the number of points a contour plate has. Earlier, the
modification of a contour plate failed if the number of points was changed.
Now it is possible to select nonparallel tapered curved rebar groups. Earlier, the
Object cannot be selected exception was thrown.
The PrimaryAxisDirection vector in the Load class is normalized when
inserting/modifying Load objects.
A new solid creation type (PLANECUTTED) has been added to the Solid class. When
the type is used, the solid consists of the raw solid, fittings and cut planes.

3.6 Tekla.Structures.Drawing 17.0.0.0


Assembly
Obsolete constructor
removed

The obsolete DrawingHandler constructor with the bool parameter


SkipChannelCreation has now been removed (the constructor was marked as
obsolete earlier). Use DrawingHandler () instead.

Obsolete AttributeFile
property removed

The duplicate attribute file name property has been removed from the View class. The
LoadAttributes method in the ViewAttributes class should be used instead.

Including part count


in the tag

The IncludePartCountInTag property has been added to the


StraightDimensionSetAttributes class.

Class for linking


dimension lines
added

A new class DimensionLink has been added.

Filtering by
ReinforcementBase

Support for filtering by ReinforcementBase has been added.

Other fixes

Changing mark properties caused unwanted free-placing of marks in some cases.


This has been fixed.
Earlier the attribute file was not loaded correctly on view insertion. This has been
fixed.

TEKLA OPEN API RELEASE NOTES


New or Changed Functionality in 17.0

3.7 Tekla.Structures.Datatypes 17.0.0.0


Assembly
Parsing distances
improved

The Distance.Parse method now supports CurrentCulture and InvariantCulture.

3.8 Tekla.Structures.Dialog 17.0.0.0


Assembly
AutoDefaults
supported

AutoDefaults are now supported in plug-in connections with PluginFormBase dialogs.

Fixes

Now the LoadAttributes method works correctly for plug-ins with PluginFormBase
dialogs.
Profiles with brackets are now written properly in the ProfileSelectionForm.
Decimal values are now using dots instead of commas.

3.9 Tekla.Structures.Catalogs 17.0.0.0


Assembly
Method removed

The method CreateRemotingChannel in the CatalogHandler class has been removed.

Getting profile names


faster

The SelectInstances property has been added to the ProfileItemEnumerator class. It


is now possible to loop through the items, getting their names, without selecting each
one of them. This feature is good for cases where only the name is necessary
because then the enumeration is faster.

RebarItem improved

The rebar item now includes all the properties available in the catalog such as the
actual diameter and weight.
The bending radius had a wrong type (string), but it has now been fixed and the type
is double.
The RebarItem.Select method has been implemented.

MeshItem improved

The mesh item property types have now been changed to follow the data types in the
mesh catalog.
The MeshItem.Select method has been implemented.
Units are now returned in millimeters.

TEKLA OPEN API RELEASE NOTES


New or Changed Functionality in 17.0

Normal folder search


order

Rebar and mesh catalogs are now searched for in the model folder, XS_PROJECT,
XS_FIRM, and XS_PROFDB.

3.10 Tekla.Structures.Analysis 17.0.0.0


Assembly
Obsolete constructor
removed

The Analysis constructor with the bool parameter SkipChannelCreation has now been
removed (the constructor was marked as obsolete earlier). Use Analysis() instead.

AnalysisModel class
fixes

Insert: Refreshes the model and adds the model to the analysis models dialog
table.
Delete: Removes the model from the analysis models dialog table.
Select: Refreshes the model.

The enumeration of analysis models does not select the models. Only the model
identifier and name are retrieved.
AnalysisModelHandler
class added

It is now possible to set and get the active analysis model, and to modify the analysis
model content.
Methods:
GetActiveModel
SetActiveModel
AddPart
RemovePart
AddLoad
RemoveLoad

- Gets the currently active model.


- Sets the active model.
- Adds a (physical) part to the analysis model.
- Removes a (physical) part from the analysis model.
- Adds a load to the analysis model.
- Removes a load from the analysis model.

TEKLA OPEN API RELEASE NOTES


New or Changed Functionality in 17.0

10

Вам также может понравиться