Hide Table of Contents

Welcome

This online reference guide documents the SOLIDWORKS Application Programming Interface (API), which you can use to automate and customize the SOLIDWORKS software.

The API contains hundreds of functions that you can call from Visual Basic for Applications (VBA), VB.NET, Visual C#, Visual C++ 6.0 , and Visual C++/CLI. These functions provide direct access to SOLIDWORKS functionality such as creating a line, inserting an existing part into a part document, or verifying the parameters of a surface.

API Help is available on the Web or locally. To enable your desired access to API Help, select Help > Use SOLIDWORKS Web Help. A check mark indicates that API Help is enabled on the Web.

NOTE: The local version of API Help is updated every service pack; however, the web version of API Help is only updated for service packs SP0, SP1, and SP5. If you want access to the most up-to-date version of API Help for service pack SP2, SP3, or SP4, use the local version of API Help.

You can find all of the SOLIDWORKS primary interop assemblies (also referred to as just interops) in the install_dir folder. You can find the SOLIDWORKS interops that you can redistribute with your application in:

  • install_dir\api\redist\CLR2 created with Microsoft .NET Framework Version 2.0. This is the version of interops to use with SOLIDWORKS VSTA (VB.NET and C#) macros.
  • install_dir\api\redist created with Microsoft .NET Framework Version 4.0.

Every supported interface available in the SOLIDWORKS API, including its associated properties and methods, is documented; undocumented SOLIDWORKS API interfaces and functions are not supported and should not be used. Obsolete APIs are not supported. SOLIDWORKS recommends that you use the most current version of the API.

Use of the SOLIDWORKS API assumes that you are familiar with VBA, VB.NET, Visual C#, Visual C++ 6.0, or Visual C++/CLI.

NOTE: All of the sample code supplied is provided on an as-is basis, and is only intended to demonstrate ways of using the SOLIDWORKS API. No representations or warranties are made regarding these samples. Any licensed user of SOLIDWORKS is free to use any or all of these samples in connection with building applications related to SOLIDWORKS, and is granted a royalty free, non-exclusive license for these samples, or parts thereof. Intellectual property rights of the samples remain with SOLIDWORKS. Any confidentiality provisions of the SOLIDWORKS license apply to the samples.

 

 



Provide feedback on this topic

SOLIDWORKS welcomes your feedback concerning the presentation, accuracy, and thoroughness of the documentation. Use the form below to send your comments and suggestions about this topic directly to our documentation team. The documentation team cannot answer technical support questions. Click here for information about technical support.

* Required

 
*Email:  
Subject:   Feedback on Help Topics
Page:   Welcome
*Comment:  
*   I acknowledge I have read and I hereby accept the privacy policy under which my Personal Data will be used by Dassault Systèmes

Print Topic

Select the scope of content to print:




x

We have detected you are using a browser version older than Internet Explorer 7. For optimized display, we suggest upgrading your browser to Internet Explorer 7 or newer.

 Never show this message again
x

Web Help Content Version: API Help (English only) 2016 SP05

To disable Web help from within SOLIDWORKS and use local help instead, click Help > Use SOLIDWORKS Web Help.

To report problems encountered with the Web help interface and search, contact your local support representative. To provide feedback on individual help topics, use the “Feedback on this topic” link on the individual topic page.