ClickOnce & References

I have created a ClickOnce solution with VS2008. My main project is referring to another project that references COM dlls as "references".

When I build my solution in VS, the DLLs from orther projects are moved to my bin folder, but when I publish and run the project, these files are not present in the Local Settings \ Apps \ 2.0 folder ....

I know that I can add every dll of another project as a link to my main project, but I would like for a cleaner solution ...

Is it possible?

0


source to share


3 answers


First add these files to your project directly. Then go to Application Properties -> Publish -> Application Files

Select "show all files" if you do not see the files you want, and then set them to publish to "Enable" NOT "Enable (Auto)". This is important or they will not be added.



Please note that if you update the files, you will have to delete them and add them again and set the publish status again. This is a small mistake.

See the previous question to my question for more information: ClickOnce - Overwriting File Contents

+2


source


You need to open the Application Files dialog box under the Publish tab of your project. From there, you can set the post type (Include, Precondition, etc.) of each of your files.



If it is an unmanaged DLL, you need to add the actual DLL as a file to your project and mark its build action as Data. Then you can set the publish type of this file to include.

0


source


I had the same problem ... and the only way to fix it after going through many options is to add these dlls to the links.

This works, but I hope there will be a cleaner solution in the future.

0


source







All Articles