See this, This solved my problem.
https://developer.tekla.com/documentation/tekla-open-api-basics-beam-application