0

I have an asp.net web site in vs2008 in which I wrote sharepoint object model code. I run my code on windows server 2003 64-bit mode and I have sharepoint 2007(64 bit mode) installed on that. However, when it comes to the following line, I get the error message:

"The Web application at ??? 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"

here is the line:

        using (SPSite site = new SPSite(mysiteURL))

I know it is a known issue, and I've searched everywhere. I tried all of the provided solutions on the internet including the following:

  1. I tried to convert it to a web application project and compile the web application in X64 target platform.
  2. I added myself to WSS_ADMIN_WPG group.
  3. My user is within site collection administrator of the sharepoint site.
  4. mysiteURL is correct.
  5. my .net framework version is 3.5.
  6. I am dbowner of the sharepoint databases.
  7. I have disabled the loopback check.
Falko
  • 17,076
  • 13
  • 60
  • 105

1 Answers1

0

Try to set the target platform to "Any CPU".

Falko
  • 17,076
  • 13
  • 60
  • 105