I am trying to create a spsite of object for sharepoint search but i am getting exception in production as website not found
SPSite site = new SPSite(\"siten
If you create a console application and try the same code there, the same code works. You have to add application to IIS and change the app pool identity. I did the same and it worked for me.