02 diciembre, 2011

Error when open an SPSite object without context

Hi all! today we have had a little bit problem when we try to open a SPSite object from a Console application:

SPSite s = new SPSite(url);

The Web application at [URL] could not be found. Verify that you have typed the URL correctly. If the URL should be serving existing content, the system administrator may need to add a new request URL mapping to the intended application.

The solution maybe permissions of your Application pool user, but if you have well configured your farm you should chack your compilation platform of your Visual Studio Project.

Change the platform to x64 and the problem will be solved :)

No hay comentarios: