Sample Plugin 1 - Text To Frames
IMPORTANT NOTE: This example is not compatible with ETABS v22.0.0 , SAFE v22.0.0 , SAP2000 v26.0.0 , and CSiBridge v26.0.0 (or any later versions of these programs) . Please refer to the updated example here: NET 8 Plugin Example - All Products
On this page:
Overview
CSI Sample Plugin 1 is a simple example, created using Visual Basic 2012, which demonstrates the development of SAP2000 plugins. The plugin creates a new model, converts a line of text into frame objects, then adds these objects to the model. For testing purposes, if the text 'crash' is entered, an error message will be generated.
The following sections provide the zipped plugin project file for different target CSI programs (SAP2000, ETABS) and for different plugin types (COM, .NET).
SAP2000 .NET Plugin
Plugin zipped project file: SAP2000_Example_Plugin_NET.zip
SAP2000 COM Plugin
Plugin zipped project file: SapPlugin1720_FramesFromText.zip (Microsoft Visual Studio 2012 Zipped Project)
To enable the COM plugin in SAP2000, necessary steps include:
FAQ
How is the plugin compiled?
Answer: The plugin is already compiled as the DLL library which follows:
obj/Release/SapPlugin1720_FramesFromText.dll
Once compiled, does the plugin need to be registered with the operating system, and how is this done?
Answer: Please see the Registering COM plugins article for response.
How is the regsvr32 error, shown below, resolved when registering the plugin?
Figure 1 - regsvr32 error
Answer: The plugin should be registered using regasm, instead of regsvr32, by running the following command:
c:\windows\Microsoft.NET\Framework\v4.0.30319\regasm /codebase /tlb /verbose SapPlugin1720_FramesFromText.dll
Warning RA0000, shown below, occurs when using regasm to register the plugin. How is this resolved?
Figure 2 - RA0000 warning
Answer: The RA0000 warning may be ignored since the plugin will still function properly.
ETABS .NET Plugin
Plugin zipped project file: ETABS_NETonly_ExamplePlugin.zip (Visual Studio 2012 VB.NET)
Please refer to the "Information for Plugin Developers" page in the CSi API ETABS 2015.chm help file that is present in the ETABS 2015 program directory.