Extract Tekla Profile Information (Properties) via the Tekla API

At Tek1 we are building a Shed Builder.

A user enters in some profile information, and we must produce a shed.

In order to do that, valid profile information must be entered, but more pertinent to this post, we also need the CORRECT heights of different profiles.

How is that obtained via the Tekla API?

        public double getHeight(string profileString)
        {
            LibraryProfileItem libraryProfileItem = new LibraryProfileItem();
            libraryProfileItem.Select(profileString);

            List<ProfileItemParameter> parameters = libraryProfileItem.aProfileItemParameters.Cast<
            ProfileItemParameter>().ToList();
            double height = parameters.First(p => p.Property.ToUpper() == "HEIGHT").Value;    		
            return height;
        }
        
// and call it like so:

double height = getHeight("CC200*75*5.0");
// voila!

Gripe Alert!

Some notes:

  • We have to cast because Tekla for some reason gives us an ArrayList. Then we have to search for the relevant parameters and handle any exceptions.
  • Notice how the API calls aProfileItemParameters. I’m not even sure what that means, or why the API is so unusable. I see no good reason why it cannot be strongly typed via a base class.

Moreover, none of this is documented, which makes it hard to use the API.

Video Demo

Written on May 14, 2026