[{"data":1,"prerenderedAt":122},["ShallowReactive",2],{"djypGQjrRurgh5UbFAD-7YXNrK0YQdZ_qimYgt4QxfQ":3,"article_automation-using-solidworks-simulation-api_solidworks":10,"_apollo:default":120,"_apollo:identified":121},{"mailchimpAudience":4},{"actionUrl":5,"slug":6,"locale":7,"default":8,"__typename":9},"","automation-using-solidworks-simulation-api","en","https:\u002F\u002F3ds.us3.list-manage.com\u002Fsubscribe\u002Fpost?u=ed4601044e1936748c0d2aa6b&id=e5080ff9fe&f_id=002d4de2f0","MailchimpAudience",{"posts":11},{"nodes":12,"__typename":119},[13],{"id":14,"slug":6,"title":15,"uri":16,"excerpt":17,"locale":18,"featuredImage":21,"tableOfContents":29,"content":30,"date":31,"authorJobTitle":5,"author":32,"masterings":44,"globalTags":48,"products":67,"disciplines":79,"seo":108,"__typename":118},"cG9zdDozNjk0NQ==","Automation using SOLIDWORKS Simulation API","\u002Fproducts\u002Fsolidworks\u002Fautomation-using-solidworks-simulation-api","\u003Cp>The SOLIDWORKS Simulation Application Programming Interface (API) functionality can be used to…\u003C\u002Fp>\n",{"locale":19,"__typename":20},"en_US","Locale",{"node":22,"__typename":28},{"large":23,"__typename":24,"medium_large":23,"thumbnail":25,"srcSet":26,"sizes":27},"https:\u002F\u002Fblog-assets.solidworks.com\u002Fuploads\u002F2025\u002F12\u002Fapi1.png.webp","MediaItem","https:\u002F\u002Fblog-assets.solidworks.com\u002Fuploads\u002F2025\u002F12\u002Fapi1-150x150.png.webp","https:\u002F\u002Fblog-assets.solidworks.com\u002Fuploads\u002F2025\u002F12\u002Fapi1.png.webp 745w, https:\u002F\u002Fblog-assets.solidworks.com\u002Fuploads\u002F2025\u002F12\u002Fapi1-300x250.png.webp 300w","(max-width: 640px) 100vw, 640px","NodeWithFeaturedImageToMediaItemConnectionEdge",[],"\u003Cp>The SOLIDWORKS Simulation Application Programming Interface (API) functionality can be used to automate the creation of studies, applying loads and fixtures, material selection, meshing, running analyses and processing results. The API provides a powerful platform for automation as well as productivity gains for any user who needs to build custom inputs or outputs to drive Simulation studies or has to work past user interface limitations.\u003C\u002Fp>\u003Cp>The API contains functions that can be called from Visual Basic for Applications (VBA), VB.NET, C++ 6.0, C++.NET, and C#.NET. While knowledge of any above programming languages will help; my goal in this article is to provide you with a self-training excel automation file and a sample SOLIDWORKS part file.  Before I walk you through the steps for using the attached files, here are some practical applications of the API.\u003C\u002Fp>\u003Cp>In the example below of a nonlinear analysis to simulate the push and snap operation of a latch mechanism, manually transferring the data of displacement and reaction force for each time step takes roughly about 20 minutes.\u003C\u002Fp>\u003Cp>Using the Simulation API macro, this takes less than a minute to complete with further customization of data in excel and auto creation of XY plots!\u003C\u002Fp>\u003Cdiv class=\"ds-video\">\u003Ca data-3ds-videoplayer=\"modal\" href=\"https:\u002F\u002Fwww.youtube.com\u002Fwatch?v=0Mg1898IbAI\" target=\"_blank\">\u003Cspan class=\"ImageCover Border Block\" style=\"background-image: url(https:\u002F\u002Fimg.youtube.com\u002Fvi\u002F0Mg1898IbAI\u002Fhqdefault.jpg); width:100%; height: 100%;\">\u003Cspan class=\"Btn--circle isCenter\">\u003Ci class=\"Icon Icon--playBig\">\u003C\u002Fi>\u003C\u002Fspan>\u003C\u002Fspan>\u003C\u002Fa>\u003Cspan>\u003Cfigure class=\"wp-block-embed is-type-rich is-provider-embed-handler wp-block-embed-embed-handler wp-embed-aspect-16-9 wp-has-aspect-ratio\">\u003Cdiv class=\"wp-block-embed__wrapper\">\u003C\u002Fdiv>\u003C\u002Ffigure>\u003C\u002Fspan>\u003C\u002Fdiv>\u003Cp>There are basic API codes \u002F calls as shown above that help establish access to a simulation study. This is the fundamental building block for everything you can control within simulation such as creating a study, controlling material choices, applying loads \u002F fixtures \u002F connectors on desired geometry, mesh settings, processing results etc.\u003C\u002Fp>\u003Cfigure class=\"wp-block-image size-large\">\u003Cimg loading=\"lazy\" decoding=\"async\" width=\"615\" height=\"321\" src=\"https:\u002F\u002Fblog-assets.solidworks.com\u002Fuploads\u002F2025\u002F12\u002Fapi7-615x321-1.png.webp\" alt=\"\" class=\"wp-image-36951\" srcset=\"https:\u002F\u002Fblog-assets.solidworks.com\u002Fuploads\u002F2025\u002F12\u002Fapi7-615x321-1.png.webp 615w, https:\u002F\u002Fblog-assets.solidworks.com\u002Fuploads\u002F2025\u002F12\u002Fapi7-615x321-1-300x157.png.webp 300w\" sizes=\"auto, (max-width: 615px) 100vw, 615px\" \u002F>\u003C\u002Ffigure>\u003Cp>Now, we’ll go over an example to get hands on with the API. Here are the instructions you should follow: Download the files contained in the first bullet below by clicking on “SimAPIs”. The filed named ‘EndLink.sldprt’ is the 3D CAD Model that we will use in this example. The file called ‘ExcelToSim_Labs.xls’ is the excel file for the APIs. Note that the SOLIDWORKS 2015 release is required.\u003C\u002Fp>\u003Cul class=\"wp-block-list\">\n\u003Cli>Download files: \u003Ca href=\"https:\u002F\u002Fblog-assets.solidworks.com\u002Fuploads\u002F2025\u002F12\u002Fsimapis.zip\" data-id=\"36959\">SimAPIs\u003C\u002Fa>\u003C\u002Fli>\n\u003Cli>Launch SOLIDWORKS.\u003C\u002Fli>\n\u003Cli>Open the file called “EndLink.sldprt”.\u003C\u002Fli>\n\u003Cli>Ensure SOLIDWORKS Simulation is checked \u002F added in SOLIDWORKS. Delete any Simulation studies that may exist in the model.\u003C\u002Fli>\n\u003Cli>Open the excel file. If you get a security warning message, simply click on “Enable Content”.\u003C\u002Fli>\n\u003C\u002Ful>\u003Cfigure class=\"wp-block-image size-large\">\u003Cimg loading=\"lazy\" decoding=\"async\" width=\"449\" height=\"218\" src=\"https:\u002F\u002Fblog-assets.solidworks.com\u002Fuploads\u002F2025\u002F12\u002Fapi8.png.webp\" alt=\"\" class=\"wp-image-36952\" srcset=\"https:\u002F\u002Fblog-assets.solidworks.com\u002Fuploads\u002F2025\u002F12\u002Fapi8.png.webp 449w, https:\u002F\u002Fblog-assets.solidworks.com\u002Fuploads\u002F2025\u002F12\u002Fapi8-300x146.png.webp 300w\" sizes=\"auto, (max-width: 449px) 100vw, 449px\" \u002F>\u003C\u002Ffigure>\u003Cul class=\"wp-block-list\">\n\u003Cli>Ensure that you have the SOLIDWORKS Window and the Excel window side by side.\u003C\u002Fli>\n\u003Cli>In excel, click the “Create a Study” button. This should create a study named “Strength” in SOLIDWORKS.\u003C\u002Fli>\n\u003Cli>Next click “Assign Material” button. The API macro is programmed to apply a 1060 Alloy.\u003C\u002Fli>\n\u003Cli>Click on the remaining buttons in excel, one at a time and notice how the fixture, load, mesh and the run is automated.\u003C\u002Fli>\n\u003Cli>Finally click on the button “Get Results” to automatically extract the maximum stress and displacement in the model.\u003C\u002Fli>\n\u003C\u002Ful>\u003Cp>Review the few lines of code used when each of the buttons in excel is clicked. This should help you get familiar with the API needed to automate the most common tasks.\u003C\u002Fp>\u003Cfigure class=\"wp-block-image size-large\">\u003Cimg loading=\"lazy\" decoding=\"async\" width=\"615\" height=\"148\" src=\"https:\u002F\u002Fblog-assets.solidworks.com\u002Fuploads\u002F2025\u002F12\u002Fapi9-615x148-1.png.webp\" alt=\"\" class=\"wp-image-36953\" srcset=\"https:\u002F\u002Fblog-assets.solidworks.com\u002Fuploads\u002F2025\u002F12\u002Fapi9-615x148-1.png.webp 615w, https:\u002F\u002Fblog-assets.solidworks.com\u002Fuploads\u002F2025\u002F12\u002Fapi9-615x148-1-300x72.png.webp 300w\" sizes=\"auto, (max-width: 615px) 100vw, 615px\" \u002F>\u003C\u002Ffigure>\u003Cfigure class=\"wp-block-image size-large\">\u003Cimg loading=\"lazy\" decoding=\"async\" width=\"615\" height=\"308\" src=\"https:\u002F\u002Fblog-assets.solidworks.com\u002Fuploads\u002F2025\u002F12\u002Fapi10-615x308-1.png.webp\" alt=\"\" class=\"wp-image-36954\" srcset=\"https:\u002F\u002Fblog-assets.solidworks.com\u002Fuploads\u002F2025\u002F12\u002Fapi10-615x308-1.png.webp 615w, https:\u002F\u002Fblog-assets.solidworks.com\u002Fuploads\u002F2025\u002F12\u002Fapi10-615x308-1-300x150.png.webp 300w\" sizes=\"auto, (max-width: 615px) 100vw, 615px\" \u002F>\u003C\u002Ffigure>\u003Cp>Next try something more fun by executing the process on your own models. Good luck!\u003C\u002Fp>\u003Cp>\u003Ca href=\"https:\u002F\u002Fwww.solidworks.com\u002Fsw\u002Fresources\u002Fvideos\u002Fsolidworks-simulation-solutions.htm?scid=sm_bl_API\" data-id=\"36959\">\u003C\u002Fa>\u003C\u002Fp>\u003Cfigure class=\"wp-block-image size-large\">\u003Cimg loading=\"lazy\" decoding=\"async\" width=\"525\" height=\"166\" src=\"https:\u002F\u002Fblog-assets.solidworks.com\u002Fuploads\u002F2025\u002F12\u002Fsimbanner-1.jpg.webp\" alt=\"\" class=\"wp-image-36091\" srcset=\"https:\u002F\u002Fblog-assets.solidworks.com\u002Fuploads\u002F2025\u002F12\u002Fsimbanner-1.jpg.webp 525w, https:\u002F\u002Fblog-assets.solidworks.com\u002Fuploads\u002F2025\u002F12\u002Fsimbanner-1-300x95.jpg.webp 300w\" sizes=\"auto, (max-width: 525px) 100vw, 525px\" \u002F>\u003C\u002Ffigure>\u003C!-- \u002Fwp:post-content -->","2015-03-04T07:00:42",{"node":33,"__typename":43},{"nicename":34,"description":35,"slug":34,"name":36,"firstName":37,"lastName":38,"avatar":39,"__typename":42},"rlakshmipathy","Senior Territory Technical Manager at Dassault Systemes SOLIDWORKS","Ramesh Lakshmipathy","Ramesh","Lakshmipathy",{"url":40,"__typename":41},"https:\u002F\u002Fsecure.gravatar.com\u002Favatar\u002Fd51b21740ec16afb8d8ebd8945c46a959154027207bea8f621b598709e15cf19?s=96&d=mm&r=g","Avatar","User","NodeWithAuthorToUserConnectionEdge",{"nodes":45,"edges":46,"__typename":47},[],[],"PostToTaxonomy_masteringConnection",{"nodes":49,"__typename":66},[50,56,61],{"id":51,"name":52,"slug":53,"uri":54,"__typename":55},"dGVybTo5NjAx","3D CAD","3d-cad","\u002Ftags\u002F3d-cad\u002F","Taxonomy_tag",{"id":57,"name":58,"slug":59,"uri":60,"__typename":55},"dGVybTo5NjA3","Simulation","simulation","\u002Ftags\u002Fsimulation\u002F",{"id":62,"name":63,"slug":64,"uri":65,"__typename":55},"dGVybTo5NjAz","SOLIDWORKS","solidworks","\u002Ftags\u002Fsolidworks\u002F","PostToTaxonomy_tagConnection",{"edges":68,"nodes":76,"__typename":78},[69],{"isPrimary":70,"node":71,"__typename":75},false,{"id":72,"name":63,"slug":64,"uri":73,"__typename":74},"dGVybTo1Ng==","\u002Fproducts\u002Fsolidworks\u002F","Taxonomy_product","PostToTaxonomy_productConnectionEdge",[77],{"id":72,"name":63,"slug":64,"uri":73,"__typename":74},"PostToTaxonomy_productConnection",{"nodes":80,"edges":101,"__typename":107},[81,93],{"id":82,"name":52,"slug":53,"uri":83,"parentId":84,"disciplines":85,"__typename":92},"dGVybTo2MA==","\u002Fdisciplines\u002F3d-cad\u002F","dGVybTo1OA==",{"nodes":86,"__typename":91},[87],{"title":52,"uri":88,"parentId":89,"__typename":90},"\u002Fdisciplines\u002Fdesign-engineering\u002F3d-cad","cG9zdDozNzcz","Discipline","Taxonomy_disciplineToDisciplineConnection","Taxonomy_discipline",{"id":94,"name":58,"slug":59,"uri":95,"parentId":96,"disciplines":97,"__typename":92},"dGVybTo4NQ==","\u002Fdisciplines\u002Fsimulation\u002F",null,{"nodes":98,"__typename":91},[99],{"title":58,"uri":100,"parentId":96,"__typename":90},"\u002Fdisciplines\u002Fsimulation",[102,105],{"isPrimary":70,"node":103,"__typename":104},{"parentId":84,"id":82,"name":52,"slug":53,"uri":83,"__typename":92},"PostToTaxonomy_disciplineConnectionEdge",{"isPrimary":70,"node":106,"__typename":104},{"parentId":96,"id":94,"name":58,"slug":59,"uri":95,"__typename":92},"PostToTaxonomy_disciplineConnection",{"canonical":109,"title":110,"metaDesc":5,"opengraphAuthor":5,"opengraphDescription":111,"opengraphTitle":15,"opengraphUrl":109,"opengraphSiteName":112,"opengraphPublishedTime":113,"opengraphModifiedTime":114,"twitterTitle":5,"twitterDescription":5,"readingTime":115,"metaRobotsNoindex":116,"__typename":117},"https:\u002F\u002Fblog-contrib-prd.itvpc.solidworks.com\u002Fproducts\u002Fsolidworks\u002Fautomation-using-solidworks-simulation-api\u002F","Automation using SOLIDWORKS Simulation API - Blog Solidworks","The SOLIDWORKS Simulation Application Programming Interface (API) functionality can be used to…","Blog Solidworks","2015-03-04T12:00:42+00:00","2026-02-13T02:40:07+00:00",3,"index","PostTypeSEO","Post","RootQueryToPostConnection",{},{},1778741322423]