Solidworks vsta

Hello @tous
Could you tell me how to make the vsta macro types reappear on my sw 2022, the goal is to continue using the macro buttons.

On sw 2018 everything is normal

According to my research, and from 2021 the vsta 3.0 has been integrated by default in sw, (there is no longer the system option uncheck activate vsta 3.0 ) to work with previous versions, on the other hand in the sw help the vsta macros are still present for these sw versions! ,
My question is how to make them work?, I found an adding technique but seems too complex to me to turn a simple macro button.!?
Thank you for your help.

1 Like

It seems that a vsta version needs to be installed Ref

1 Like

Yes, that's it, you absolutely have to install visual studio (the latest version compatible with your solidworks- imperatively)
For me visual studio 2015 (Sw2020)

1 Like

Hello @sbadenis
This explains the fact that it didn't work with my vsta 2010, unfortunately it won't solve my problem, I don't see how to install such a large environment for each workstation :sweat_smile:

1 Like

@Lynkoa15 , you can install Visual Studio on one workstation (yours), compile your visual studio code and then no need for visual studio on the other workstation you launch a compiled DLL.
From memory that's how it works, without having to install Visual studio on each workstation.
Edit: see this post where @remrem explained this to me:

1 Like

That's the problem sbadenis, to assign the compilations, you have to have the vsta extensions (or the addins, I think), it was possible for the previous versions but doesn't seem anymore :pensive:
(I tried to compile in. Exe then launch the program via. Swp, it works but the execution time is not possible,)

On Version 2020, I just tested on a workstation where Visual Studio is not installed and you can run a dll:
image
On the other hand, it is not possible to open the project on these workstations, only the compiled version.

2 Likes

I haven't been able to find the reference but it's from 2021 that it's no longer possible (in any case I appreciate the help and the sbadenis trials, thank you)

1 Like

This is the link you are looking for:
https://help.solidworks.com/2021/English/api/sldworksapiprogguide/GettingStarted/VSTA_2015.htm
And for me no change in the running part at the bottom of the page nor in 2021 or 2022.
After all, I'm not a pro in the field, I only relay the information gleaned right and left.
Edit:
The answer was there:

1 Like

Yes I remember that box, unfortunately not present anymore


Yet it is marked:

So since the 2021 no longer to checkmark installed by default? And you can't find the dlls in the choice of macro, that's right.
No one else with 2021 or 2022 version to test?

1 Like

And this option is well checked :crazy_face::

1 Like

Exactly

Yes it's enabled by default, there's no longer the checkbox, I even tried to uncheck it via api but no longer supported (deprecated functions)

No other idea, if anyone else has other proposals?

2 Likes

At home in 2022 version on my colleagues' workstations where Visual Studio 2015 is not installed, they can edit VBA (.swp) only but can run .dll so now I'm drying.
Reinstalling SolidWorks? Ask for technical support?

We're talking about only running the .dll and not modifying macros, do we agree?

2 Likes

Hello @tous
@Konti, I have always installed myself and carefully, it can happen to miss something but :wink:I can't :pensive:find it.
I tried to follow @sbadenis's advice by installing a version of vsta (2022 with runtime for a test), and there the extension reappears so I guess it's not a problem with my installation,
According to sw's previous reference


There must be a vsta option in the sw 2022 distribution, I don't know why this is not the case for my distribution, but if you could confirm it would be nice of you.

Hello
I've had this type of problem before. It is mentioned in the help that if you install Visual Studio after SW, this may be a problem.
From memory, I had solved the problem by repairing the VS installation.
Have a nice day.

Hello @remrem
That's exactly what I did, after installing a vsta version, the extensions reappeared.
Thank you and have a good day

1 Like