API Reference

Detailed and full API reference helps you master Tekla development

This is the most recent version of Tekla Open API.
For older versions, please visit Tekla Warehouse.

ShapeItemExport Method

Exports the shape item in *.tsc-format to the to given file name. If path is not given shape is exported to model folder. If filename is empty shape name is used as filename.

Namespace:  Tekla.Structures.Catalogs
Assembly:  Tekla.Structures.Catalogs (in Tekla.Structures.Catalogs.dll) Version: 2023.0.1
public virtual bool Export(
	ref string filename


Type: SystemString
The export file name of the shape item.

Return Value

Type: Boolean
True on success.
using System;
using Tekla.Structures.Catalogs;

public class Example
       public void Example1()
           ShapeItem item = new ShapeItem();
           string shapeName = "myShape";
           if (item.Select(shapeName))
               string filename = System.IO.Path.GetTempPath() + "\\" + shapeName;
               if (item.Export(ref filename))
                   Console.WriteLine("Shape item exported successfully");
See Also
Was this helpful?
The feedback you give here is not visible to other users. We use your comments to improve the content.