VSTO installer and Deployment Manifest file - visual-studio

I am trying to make an installer for a PowerPoint Addin using Visual Studio Installer.
The installer installs each required files but does not execute the VSTO Deployment Manifest, and then my add-in is not included in PowerPoint.
I went to Custom Actions menu and wants to add the action of executing VSTO Deployment Manifest file but I have the following error: not a valid file type for a custom action (it seems to expect .exe .dll .vbs or .js files).
I have searched similar questions and found it but even if the error message is the same, I think the problem is different.
Do you know how to solve it and execute the VSTO Deployment Manifest file?

Related

VSTO Outlook: HOWTO add a manifest file app.manifest

I have an VSTO Outlook Add-in which uses some WPF components. I have some problems on WPF components to be rendered correctly. For example, some objects are shown more bigger, etc. I have found a possible solution described here when you mix winform and wpf components. May I guess VSTO Outlook addin in fact are winforms? So I need to specify some configuration in an app.manifest file and I do not know how to create the manifest file. I don't know if the process to create it is the same as a normal winforms app or in case of an Outlook VSTO Add-in is different.
In the link I provided above it is explained to add some setting in the assemblyinfo.cs file, ok there is no problem with it, i have done it, but now I do not know how to add some settings to the app.manifest file. I have seen in the \bin\release folder I have an myAddin.dll.manifest but this file is created automatically when you build the Add-in so i guess i cannot touch it because if so it will be overwritten again when I do a new build/rebuild of my add-in. Also the content within myAddin.dll.manifest, from where is taken?
Please could you indicate me the steps i must follow?
UPDATE:
This link says application manifest file is created automatically, as I was guessing.
Application manifests are created automatically as part of the build
process.
So is there any way to create a post-build action to add a custom setting to application manifest?
One possibility would be to modify the manifest MyAddin.dll.manifest after build process suceed but i would like to automate it. Also i am wondering if there is the possibility to create an additional manifest file and Visual Studio merge it with the default one during the building process.
VSTO add-ins are not standalone applications like Windows Forms. The manifest file is created per-application, not add-in. So, the best what you could do is to create a manifest file for the host application which is Outlook in your case. The manifest file should be named in the following way:
Outlook.exe.manifest
and should be placed to the same folder with Outlook.exe application.
So, if you need to make changes with a manifest file they will be applied to the whole host application (Outlook) and have impact on all add-ins, not only yours.
The manifest works on the application level (exe), but VSTO addins are dlls hosted by outlook.exe, and you cannot add or update its manifest.

Visual Studio Advanced Installer Extension - how to package app.config files in console app

I am using the Advanced installer extension in Visual Studio 2019 to package a console application. It works fine except that it does not package/install any of the .config files (such as myexe.exe.config).
Does anyone know how to get it to do this? The console application has transforms using SlowCheetah and on build places them correctly into the bin// directory.
I would expect these files to be listed as 'primary content' and exist.
You can manually add (one-time operation) the .config file in your setup project using the [Edit in Advanced Installer] button. Have a look on their video tutorial.

How to add and run an additional manifest in a VSTO Add-in

I have a VSTO Add-in in C# for Excel in Visual Studio 2017.
I also have a manifest which references a Web Add-in for Excel.
I'd like to add the manifest to the VS project so that when the user installs the VSTO add-in, the web add-in will be installed as well.
I have found several ways to add a manifest to a VS project:
1. Create the manifest through New File -> Add Manifest Application File
2. Add a Web Add-in to a solution
However, these 2 ways aren't enough to achieve what I'm trying to do.
With the first method, the manifest is added to the project, but nothing reads it so it is never loaded.
Moreover, I thought I could specify it as an additional manifest, but VS doesn't let me embed it:
With the second method, I successfully added a Web add-in project to my solution.
When set as additional start up project, it loads and runs correctly on debug mode.
However, when I build my solution, the web add-in doesn't generate anything, so it isn't embeded in my installer (I'm using Wix 3.11 to generate a .msi installer), and thus, it is never run when I install the add-in.
How can I add and read the manifest in my solution so it will run upon installation?
EDIT:
I have also found this to use AdditionalManifestFile in (I believe) the .csproj of a project, however this doesn't work either.

Creating installation files depended on NuGet packages doesn’t work in Microsoft Visual Studio 2017 Installer Projects

Is it possible to get pug in project for Outlook that is depend on NuGet packages to be installed with Microsoft Visual Studio 2017 Installer Projects? I’m trying to create an installation file for a plug in for Outlook that have a drag and drop functionality dependent on the Easyhook Nuget package. That the plugin have a taskPane with a webbrowser there are drop Outlook e-mail messages as .msg files.
It works to install the plug in but the drag and drop functionality that is dependent on the NuGet package doesn’t work. That I can drop the message but the webpage doesn’t recognize the drop mails as .msg files or even as uploadable files. While if I try with the trial version of InstallShield 2018 Express Edition everything works including the drag and drop functionality.
I tried to do the same thing with Installer Project as with InstallShield. To output I added content files, debug symbols and primary output. Files I added was the manifest and vsto files for the Plugin and the .dll file for the NuGet Package, Easyhook32.dll. I got an error because the content file included the 64bit for the NuGet Package files, and I’m doing a 32bit installation, and also that the Easyhook32.dll file was duplicate, that it seems that the dll file also was added with the content files.
So, I excluded the 64bit files in the plug In project that should be installed and in the installation project I removed Easyhook32.dll files from the files that should be include in the installation. Also then it worked to install the plugin but the drag and drop functionality didn’t work. I also tried to for example not add the content files and just add the Easyhook32.dll and that also made the installation work except the drag and drop functionality.
I can of course also try other installation programs that is able to add NuGet but also are able to be installed from the Internet and also add registry keys and values. That I also have tried Microsoft Click Once installations program and it was easy to create an installation files but it seems like you need a valid certification if you want users to download the installation file from the Internet.
Also, this is the first time I working with type of installation like this ones and with Outlook Add In so I can have missed some obvious solutions. That at the same time english is not my first language so I can also have missed using the correct terminology.
NuGet is a build-time package manager. You'll need to redistribute any required binaries in your installer package by adding them manually. Typically, required binaries from NuGet packages will be copied to your output folder, so you could add them from those paths just like your project output.

Outlook Add-ins manifest and Installer folder VSTO

I'm developing an outlook addins vsto using visual studio 2010,
When I publish my project I found a new install folder inside "Application Files\MyAddin_version\Installer\MyAddin.exe.deply"
This is a new file with the deploy, before I was able to deploy without this file.
My question, what setting in my build generate this file?
The problem every time I build my project now I found in the manifest file the new entry:
I'm pretty sure the entry was not found in the old builds, I didn't change the code, but I was trying to change the build and publish, switching between local publish and UNC and http.
(Need to remove this new entry, don't need it every time i build, it causes problem.)
Many Thanks
Sorry it was a bug in my solution, some files were marked as content in the build actions.

Resources