I'm running Visual Studio 2017 Community on Windows 10, and have created a VSTO Excel extension. I have admin on the sandboxed windows 10 machine, but only user access on the Windows 7 box. The Windows 7 box runs .Net 4 and I cannot change that.
From the start of the project I have set the target to .Net Frameworks 4 Client and the Installer project Launch condition also set to Net 4 Client. The extension is for Office Excel 2010. It compiles and works in my Windows 10 box.
I also successfully ran it, when I manually installed the excel extension to a windows 7 box running .Net 4. ( i.e. directly copying the .dll files, vsto files, etc, and then using regedit to set up the addin reg settings.). It works flawlessy on the Win 7 box.
When I run the msi installer file, it installs fine on my win 10 box, and fails to install on Win 7 box (it reports a successful install but the install directory is empty, and I have to run the msi again to remove the "non-existant" installation) .
Setup.exe works on Win 10 box, but on the Windows 7 box insists on installing Net 4.6.1 and when I cannot (I'm not admin), the installation fails.
I then wrote another excel extension that did nothing but messagebox "Hello World" on excel startup. It showed exactly the same problem.
Why does setup insist on installing .Net 4.6.1 when I have set the target to Net 4 Client, the launch condition to the same and the extension works perfectly on Win 7 Net 4 when I manually install?
What am I missing?