Has VS 2010 SP1 changed where the .config file is picked up from in VSTO add ins? - web-services

I have an outlook 2010 add-in that has a service reference to a simple web service we have set up.
The config for the service is in the app.config file.
This add-in is deployed using windows installer into the program files folder.
This has been working without a problem until yesterday.
Yesterday I installed VS 2010 SP1 and now when the add-in tries to access the web service it has the error "Could not find default endpoint element that references contract in the ServiceModel client configuration section."
Does anyone know what has changed and what is causing this problem?
If I open the project in VS, build and then run from within VS the config is picked up fine.
Thanks
Gavin

The actual solution is more simple. There was a breaking change made to VSTO 4 sp1 in that the manifest has to be a fully qualified URI. So when building your setup project, you must prefix the path to the manifest with file:/// and everything works as you'd expect again. They didn't get the documentation and tutorial pages updated in time for the release. I'm not sure that they have been yet.

Perhaps you're hitting a problem with extensionless services after installing SP1? http://support.microsoft.com/kb/2468871 - Issue 16?

I had this exact same problem. After installing Visual Studio sp1 (which installs VSTO 4 sp1), my Outlook addin could no longer find its config file for service endpoints. The only solution I've found so far is to run the VSTO setup (the new one) and choose uninstall, then run the old version that was previously installed and rebuild the setup package. If the new version is installed on the client machine, that machine will have this issue. Your setup may not detect it because typically you specify a minimum version for it to look for. I haven't found any other info about others having this problem besides yourself or anything official from MS about the problem.

Related

Why did Windows 10 upgrade break VS 2017 with IIS Express?

Did the latest Windows 10 upgrade on 8/27/2019. That broke Outlook 2016, but an Office Repair tool fixed that.
Now my VS Community 2017 can't run a Web project because IIS Express won't start. Says some other app is using the port, but SysInternals and netstat -ano say otherwise. In the Windows application log, an error for Clr4IntegratedAppPool always fires before the IIS error.
I have tried all of the following:
Repair VS 2017 (took hours to download gigs of stuff; what was this, an entire reinstall?)
Uninstall/reinstall IIS Express and reboot, reboot, reboot.
Delete the folder My Documents/IIS Express.
Delete the hidden project file .vs/config/applicationhost.config.
Changed the port number in the VS project properties, on the Web tab.
Ran this command: netsh http add iplisten ipaddress=::
I created a new web project and it ran fine with IIS Express. But after that, the old project still could not keep IIS Express running.
Suggestions?
When I compared the csproj files for the new project that worked and the old one that had stopped working, I found that the new one had a lot of IIS-related stuff that was absent from the old one. I copied it from the old to the new, and it worked. However, it only worked with the new port number. Haven't gotten the old one to work, but I'll gladly settle for that!
<WebProjectProperties>
<UseIIS>True</UseIIS>
<AutoAssignPort>True</AutoAssignPort>
<DevelopmentServerPort>57919</DevelopmentServerPort>
<DevelopmentServerVPath>/</DevelopmentServerVPath>
<IISUrl>http://localhost:57919/</IISUrl>
<NTLMAuthentication>False</NTLMAuthentication>
<UseCustomServer>False</UseCustomServer>
<CustomServerUrl>
</CustomServerUrl>
<SaveServerSettingsInUserFile>False</SaveServerSettingsInUserFile>
</WebProjectProperties>

Click Once application works when published from Visual Studio 2010 but not Visual Studio 2017

VS2017 publish causes error on startup "cannot load file or assembly ..." Running directly from the build works but not from the deployment in app.publish folder. The error shows even on my development computer. However, opening the same solution in VS2010 and publishing from there, all works as expected. I cannot find this same issue on the web.
After searching for all things Click Once, I came across an answer for a different issue and tried it. I upgraded the target framework to .NET Framework 4.6.1 and updated the NuGet Packages. Afterward, I was able to publish and run the Click Once Application with no errors.

Nuget restore for some team members does not work - Microsoft.AspNet.Mvc and other core packages

I'm using Visual Studio 2015 community along with some other in our team. A mvc web application that I created works fine on my machine but when others get it to build, all packages download successfully but some of the core MVC such as Microsoft.AspNet.Mvc, Razor, etc don't install.
What was weird that on their machine, if they went into PM and downgraded the MVC package to 5.2.2 and then upgraded back to 5.2.3 it worked. But now when setting up the build on our build server, we get the same issue!
Any ideas why this bizarre behavior?
Didn't check that but why would that matter? When the Dev downgrades the version on 1 package and then upgrades back everything is as it should be
EDIT (4th Oct 2016) after investigating a bunch of things:
One of the developers at one point committed the "Packages" folder which sits at the root which had the "Microsoft.AspNet.Mvc" and other folders but without the dlls. This made the "Restore packages" not really "Restore" these as the folder already existed but when the build was run the artifacts weren't actually there in the folder to be moved into bin.
I deleted the packages folder, added it to gitignore and committed the change which made everything 'green'!

Team Build ignores MSBuild arguments

I have created a new team build definition. On every checkin, the build happens on a TFS server (another build controller). After the build completes, I want to publish the files. The MSBuild input arguments used are /p:DeployOnBuild=true;PublishProfile=QADeploy. QADeploy is the publishing profile created.
I expect the team build to succeed which happens. But the successful build does not publish or attempt to publish the files to the destination folder. Any ideas why, the publish via publish profile is not triggered?
Weird, but adding the Visual Studio Version resolved the problem:
/p:DeployOnBuild=true /p:PublishProfile=QADeploy /p:VisualStudioVersion=11.0
I had the same issue and was pulling my hair out. Check out this Similar Problem, it helped me.
I fixed it via copying both WEB and WEB APPLICATION web build targets from this path on a PC with VS installed into the matching path on the build server:
C:\Program Files\MSBuild\Microsoft\VisualStudio\v11.0
(path for VS 2012)
I am not sure if their suggestion of using the full installer for web deploy helps. I tried both suggestions at the same time and it worked there after.
Also it only works on a Web Project

no metro style templates in VS2012 ultimate on windows 8

I have a VM with windows 8 x64 bit and I installed VS2012 ultimate from microsoft webiste. It prompted me for the developer license - I clicked ok. It asked me to signin to microsoft account. I created one and signed it and it worked. but when I try to create new project, I didnt see any metro style app templates.
I tried uninstall and install again but no progress.
please help. I dont see the metro style folder in project templates \csharp.
when I downloaded http://go.microsoft.com/fwlink/?LinkId=247147 it went close, I saw the metro style folder in templates but the installation threw error at the end - iis8 install error and vs did not open either.
What was previously referred to as a "metro" template, is now the "Windows Store App" template.