简体   繁体   中英

Can you build an Outlook 2010 add in using .NET 4.5 framework in Visual Studio 2012?

I recently built a Outlook 2010 add in (in C#) using the .NET 4.0 Client profile framework in VS2010 but I would like to use the System.Net.Http library, which is under the .NET 4.5 framework and so I installed VS2012 to be able to do this. However, I only have Outlook 2010 installed on my machine and so want to be able to run the add-in from VS2012 in Outlook 2010 but I'm unable to do so at the moment as when I go to debug this in VS2012 it says that I don't have the correct version of Outlook. So far in VS2012 I can only see options to build Outlook 2013 add-ins with the .NET 4.5 framework and not Outlook 2010, which can only been seen under the .NET 4.0 framework. Is there any way I can somehow use the System.Net.Http library with my Outlook 2010 add-in and have it available to run on Outlook 2010?

Yes, you can build and run an Outlook 2010 add-in in VS2012. You can read more about that in the Running Solutions in Different Versions of Microsoft Office article in MSDN.

Most probably you need to choose the .Net framework 4.0 in the Create New project wizard in Visual Studio to get the template visible and available:

在此处输入图片说明

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM