OS. To connect the STAAD.Pro Script Editor to STAAD Object Library
The STAAD object library, which contains OpenSTAAD,
can be referenced in the
STAAD.Pro Script Editor such that the editor
will auto-complete class and function names.
This procedure is
optional, but highly recommended in order to have your editing environment be
able to assist you in writing code.
Start the
STAAD.Pro Script Editor as an
administrator.
Performing the following steps as an administrator allows your to
make a change to the template. This prevents you from having to re-perform this
task every time you edit STAAD macros.
In Windows Explorer, locate the file C:\Program Files\Bentley\Engineering\STAAD.Pro
2024\STAAD\Bentley.Staad.ScriptEditor.exe.
Right-click on the file and then select
Run as administrator from the pop-up menu.
You are asked if you want to allow the application to make
changes to your computer. Confirm you will allow this.
The editor opens with a new macro template open.
Select the Add Reference tool in the Design
group on the Home ribbon tab.
The
References dialog opens.
Click
Browse.
The References dialog opens.
Navigate to and select
C:\Program Files\Bentley\Engineering\STAAD.Pro
2024\STAAD\StaadPro.dll and then click
Open.
Scroll through the list of
Available References to locate
OpenSTAADUI (1.0) and check this option.
Click
OK.
Now, when the
Browse Object tool () is selected, you will see
OpenSTAAD functions included in the Library list.