Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

create addin using interop 2017 #118

Open
sylbat opened this issue Mar 23, 2021 · 1 comment
Open

create addin using interop 2017 #118

sylbat opened this issue Mar 23, 2021 · 1 comment

Comments

@sylbat
Copy link

sylbat commented Mar 23, 2021

Hi,
I have used your tutorials "04 Selected objects" to create an add in of my own. This has been done using the integrated interop which are version 2020. I have a running version of SW 2020 on my laptop. The addin is finished now but I just learned that the users that should be using this addin are running SW 2017.
I tried to replace the interop 2020 with the 2017 ones, but I cannot regenerate the project in Visual Studio. The error I'm getting are all missing components.
Example :
error CS0246: The type or namespace name 'IAdvancedHoleFeatureData' could not be found (are you missing a using directive or an assembly reference?) - Project AngelSix.SolidDna - File FeatudeAdvancedHoleWizardData.cs - line 8 and line 15
I have 24 other similar messages for other features.
How should I proceed ?
thanks for your help.

@brinkdinges
Copy link
Contributor

I'd better answer this late than never. The DLL version that you use does not have to be the one that the user has. I use SW2021 DLLs and my add-ins still work on SW2017. I added SW2021 features to SolidDna a while ago, so you should keep those DLLs.

When SolidWorks starts your add-in, it already has its own DLLs loaded so it will ignore yours. But for the add-in to work perfectly, you should avoid using any features that are newer than SW2017. I do the same, and all of my bookmarks are to 2017 help pages to minimize the chance of me using newer APIs.

I also have a check in my installer that prevents users to install the add-in if they have SW2016 or older.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants