US$0.00
0

Author: Amen Jlili

SOLIDWORKS Macro to Save Assembly As Part (All Components)

Description This macro automates the process of saving a SolidWorks assembly as a single part file that includes all components. It is particularly useful for simplifying assemblies for external use or reducing file size. System Requirements Pre-Conditions Results Steps to Set Up the Macro 1. Prepare the Assembly: 2. Run the Macro: VBA Macro Code You can download the macro from here. Customization Need to modify the macro to meet specific requirements or integrate it with other processes? We provide custom macro development tailored to your needs. Contact us.

Read More »

SOLIDWORKS Macro to Save Assembly as Part (Exterior Components)

Description This macro converts an active SolidWorks assembly into a part file that contains only the exterior components. This feature is useful for reducing the complexity of the assembly when sharing with external stakeholders or for performance improvements in visualization and analysis. System Requirements Prerequisites The following conditions must be satisfied for the macro to function as intended: Results Steps to Set Up the Macro To deploy the SOLIDWORKS macro to save assembly as part utility, you must follow these simple steps: Prepare SolidWorks Configure and Run the Macro Outcome of Using the Macro VBA Macro Code Macro You can download the macro from here. Customization and Advanced Solutions by Experts To get started with customizing this macro or to create any other fully custom solutions for your engineering projects, reach out to our team of engineers today!

Read More »

SolidWorks Macro for Feature Driven Component Pattern

Description This macro creates a feature-driven pattern for all selected components in an assembly. The last selection in the list is used as the driving pattern, such as a hole feature. System Requirements Pre-Conditions Results Steps to Set Up and Run the Macro Follow these steps to outline the process, from the initial one-time file setup to the routine execution of the Feature-Driven Component Pattern utility. VBA Macro Code Macro You can download the macro from here. Build More Effective Custom Solutions With Our Team Of Experts! Contact us today to discuss your custom automation solutions – and beyond!

Read More »

SolidWorks Macro to Efficiently Manage Assembly by Hiding All Sketches

Description This macro hides all visible sketches in the active assembly. This is useful for cleaning up the view in complex assemblies where multiple sketches may clutter the workspace. System Requirements Prerequisites Results Steps to Set Up the Macro To quickly get the SolidWorks macro to efficiently manage assembly by hiding all sketches up and running, follow these brief instructions: Pro-Tip: It is highly recommended to assign a keyboard shortcut or a toolbar button to this macro to achieve maximum speed and efficiency. VBA Macro Code Macro You can download the macro from here. Customize with Expert Support Contact us today and get the most from your SolidWorks automation.

Read More »

SOLIDWORKS Macro to Export Assembly Components as Parasolid

Description The macro will traverse your open SOLIDWORKS assembly file (.SLDASM) methodically and recursively, detect each child component (part), and then proceed to automatically save each part in the stable Parasolid (X_T) format. The macro traverses recursively through the assembly structure so that each part is saved based on the part name. System Requirements Pre-requisites To execute the macro, the following conditions must be satisfied: Results The results of your automated batch export process are: Steps to Set Up the Macro VBA Macro Code Macro You can download the macro from here. Reach out, and we’d be happy to assist with integrating this or any other batch process into a more complete system based on your needs.

Read More »

Why “Class Not Registered” Happens When Loading SOLIDWORKS PDM Add-ins

If you have ever tried loading a PDM add-in and hit a confusing startup error, understanding why “class not registered” happens when loading SOLIDWORKS PDM add-ins is the first step to fixing it. This issue usually points to a broken or incomplete COM registration, often caused by mismatched permissions or missing system components. When a SOLIDWORKS PDM add-in fails to load with the message: Failed to load add-inReason: Class not registered the cause often isn’t the add-in code or COM registration itself: It’s the elevation context in which the host application runs. Windows isolates COM registrations between two different scopes: COM Registration Scope Registry Location Accessible When Per-User HKEY_CURRENT_USER\Software\Classes\CLSID The process runs non-elevated (normal user context). Per-Machine HKEY_LOCAL_MACHINE\Software\Classes\CLSID The process runs elevated (as Administrator) or system-wide. When you register your SOLIDWORKS PDM add-in (e.g. CardSync.dll) using regasm or the PDM Administration tool, it is normally stored under the current user’s profile (HKCU). However, if the host process like File Explorer, PDM Explorer, or even your test harness (Orca.Tests.exe – At Blue Byte Systems, we have developed our very own unit testing framework for add-ins), runs as Administrator, Windows will block access to any COM object registered per user. That’s exactly what the “Class not registered” dialog means. SOLIDWORKS PDM Explorer itself is not designed to run elevated. When your own executable or service is launched as Administrator, it now operates in a different COM security boundary and cannot see the user-level registration of your add-in. In the example of the screenshot above, I’m debugging inside Visual Studio (ADMIN) and launching my process from there. The moment Visual Studio is elevated, every child process (including your test harness) inherits that elevation, and therefore loses access to the per-user COM registry hive. Microsoft’s Official Explanation Applications that are run-elevated (whether manifested as RequireAdministrator or selected via Run as Administrator), as well as applications run from an Administrator account where UAC is disabled, cannot access any COM objects configured per-user. (Source: MSDN – “Manifestation” and Stack Overflow discussion) How to Fix or Avoid It Our Practical Advice If your application interacts with SOLIDWORKS PDM’s COM APIs, never run it as Administrator unless the add-in is registered per-machine.

Read More »
0
0
Your Cart
Your cart is emptyReturn to Shop