I'm testing an Outlook web add-in both in Chrome and Edge. I'm using IIS-Express (Launched from VS2017)
The icon pointed to by the "iconURL" element in the manifest file will not load. I get the following error:
Failed to load resource: net::ERR_CONNECTION_REFUSED
Clearing the browser cache didn't help.
What we noticed was that when a new test project (Outlook web Add-in) was created, everything worked normally.
We suspect that IIS-Express isn't being launched by our regular project.
We think that because we had to click the stop debugging button to end the debug session in the test Add-in, but in our regular add-in the "Start" button was still active as if no debugging session was started!
Any ideas?
In THIS particular case it turns out that IIS express wasn't running.
The VS Studio solution has two projects; and Office Web Add-in, and a WebAPI service.
The outcome of having two separate projects is that both are running under different hosts (e.g. localhost:1234 for the Add-in, and localhost:5678 for the web service).
What I did was to open the properties of Solution.
Selection your solution so that it is highlighted then select Project/Properties/Common Properties/Startup Project/Multiple Startup Projects.
I then select both my Web Service and Office Add-in to launch at the same time.
Now that IIS Express is guaranteed to be running, my Icon can be found.
NOT BEST SOLUTION Although this solved my problem. I ended up with a new problem having to do with CORS. We did not know at the time that having separate web projects could cause this.
We'll be combining the projects so that CORS concerns can be eliminated.