question

QuickBooksDev-0076 avatar image
0 Votes"
QuickBooksDev-0076 asked DanielZhang-MSFT answered

VS 2017 Setup not pulling dlls from correct folder. How can we fix this?

We have several VS 2017 VB window forms desktop programs that access the QuickBooks Online API .Net SDK dlls and some of our own dlls. All have worked for years including the one in question.

In one of them we made a programming changed and updated the NuGet components and built a new .msi from the setup project.

The installed program would not run do to the wrong dlls being used. The setup dependencies is picking up the dlls from the wrong folder. Most of these dlls are brought in from nuGet. A couple of our own dlls were not but still coming from the wrong folder.

Why are the dlls in the dependencies pointing to the wrong folder? They are not the same folders as in the app's references. How

I have redone the entire project a couple of times including starting a brand new setup project but no luck.

I do use add project output when creating the setup project.

Our other apps which use the same exact dlls do not have this problem even after many updates and new msi builds.

I think that part of the issue is that are other dlls from our other projects are sometimes included in the solution for debugging. The dlls are being duplicated in the references. But are other apps also include the same other projects without an issue.

Please help.

windows-forms
5 |1600 characters needed characters left characters exceeded

Up to 10 attachments (including images) can be used with a maximum of 3.0 MiB each and 30.0 MiB total.

1 Answer

DanielZhang-MSFT avatar image
0 Votes"
DanielZhang-MSFT answered

Hi QuickBooksDev-0076,
First, please check whether the framework version of the project is the same as the framework version of the dll you are referencing.
When adding project output, have you tried the "Locally-Copied Items" option?
And you could add it as an item to your project and set the Build Action to Content and the Copy to Output Directory to Always.
More suggestions you can refer to the following threads:
Visual Studio Installer Project does not include all dlls from output folder
Dependent DLL is not getting copied to the build output folder in Visual Studio
Best Regards,
Daniel Zhang


If the response is helpful, please click "Accept Answer" and upvote it.

Note: Please follow the steps in our documentation to enable e-mail notifications if you want to receive the related email notification for this thread.


5 |1600 characters needed characters left characters exceeded

Up to 10 attachments (including images) can be used with a maximum of 3.0 MiB each and 30.0 MiB total.