This SharePoint tutorial explains, how to resolve the issue “Microsoft SharePoint is not supported in the 32-bit process. Please verify that you are running in a 64-bit executable”. The error comes when we try to run a windows application in SharePoint 2016. Recently I was doing a demo in a windows application (Server Object Model / Microsoft.SharePoint.dll) in visual studio 2015.
When I run the application it gives me an error as:
System.PlatformNotSupportedException occurred in Microsoft.SharePoint.dll.
An unhandled exception of type ‘System.PlatformNotSupportedException’ occurred in Microsoft.SharePoint.dll
Additional information: Microsoft SharePoint is not supported in the 32-bit process. Please verify that you are running in a 64-bit executable.
The error looks like below:
To resolve this issue follow the below steps:
Open Visual Studio 2015, Right click on the Project -> Properties.
Then in the Properties page, open Build tab and then uncheck “Prefer 32-bit” in Platform target section like below:
Remember SharePoint 2016 support only 64 Bit.
Then you run the application it should be working fine.
Still, if this issue does not resolve then you can try the below solution.
This solution explains, how to resolve the issue which comes when trying to run server-side code in a console application. The error comes as: Microsoft SharePoint is not supported in a 32-bit process. Please verify that you are running in a 64-bit executable.
Open Regedit and navigate to below path: HCU\Software\Microsoft\VisualStudio\12.0\WebProjects\Use64BitIISExpress
Edit “Use64BitIISExpress” and make 0 to 1
Click ok, If still Problem is exist try below method
Open Visual studio -> TOOLS ->Options…
Select Projects and solutions on the Options wizard and select Web Projects then check the option “Use IIS Express for new file-based web sites and Projects”.
Then select OK.
You may like following SharePoint tutorials:
- Create remote event receiver sharepoint online as provider hosted add-in and deploy into Microsoft Azure step by step tutorial
- How to get all service applications using PowerShell in SharePoint 2016?
- How to find which template is used for a site in SharePoint Online Office 365
- Connect-SPOService : Current site is not a tenant administration site error in SharePoint Online Office 365 Site
- How to connect to SharePoint online site using SharePoint Online Management Shell?
- This field must be indexed to enforce unique values error while adding content types in SharePoint Online
- Retrieve term store data including Labels using .Net managed object model in SharePoint Online
- SharePoint Online Site Workflow and Initiation Form Parameters example using SharePoint designer workflow
Now you should not get the error, Microsoft SharePoint is not supported in 32-bit process. Please verify that you are running in a 64-bit executable.
I am Bijay from Odisha, India. Currently working in my own venture TSInfo Technologies in Bangalore, India. I am Microsoft Office Servers and Services (SharePoint) MVP (5 times). I works in SharePoint 2016/2013/2010, SharePoint Online Office 365 etc. Check out My MVP Profile.. I also run popular SharePoint web site SPGuides.com