OS. Start Your VB.Net Project
This quick set of steps demonstrates how to set up your workspace for a VB.Net project.
- In the Visual Studio start window, click Create a new project. The Create a new project window opens.
-
Filter the project templates using the following:
- Type console in the search field.
- Select VB from the Language drop-down list.
- Select Windows from the Platform drop-down list.
- Select the Console App (.NET Framework) from the results and then click Next. The Configure your new project window opens.
- Type OpenSTAAD Demo in the Project Name field.
- Click Create. Visual Studio opens your new project, which includes default "Hello World" code.
-
Add the staadpro.dll dependencies to the project
file.
This adds OpenSTAAD as a COM file reference.
- Open the project's .vbproj file. This file is located in the root directory of the project.
-
Add the following element to the start of the
<ItemGroup> element:
<COMFileReference Include="C:\Program Files\Bentley\Engineering\STAAD.Pro CONNECT Edition\STAAD\StaadPro.dll"> <EmbedInteropTypes>True</EmbedInteropTypes> </COMFileReference>
- Save and close the project file.