use ASP.NET MVC 2.0 to display Sharepoint Data.
when i created a class library and write a code to retrieve the data from the sharepoint and added the dll in the mvc project call the method from the mvc project and when i run the MVC Project it showing me error that " The Web application at http://abc:1234 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. " i am not getting what to do.
February 20th, 2011 11:56pm

Hi Bhavik, Are your application trying to run in 32-bit(x86)? If so, please set the project platform target to Any CPU or x64, then rebuilt the solution. Refer to “Web application at … could not be found” Error on MOSS 2007 x64 And also ensure the user running the application have the following permissions: 1. The user is a server farm administrator. 2. The user has read and write permissions on the content database. 3. The user is a site collection administrator. 4. The user has permissions to access the SharePoint site through which the code iterates. So that better support could be provided, please ask program problem in Development and Programming (pre – SharePoint 2010) forum in the future, thanks for your understanding. Best regards, Emir
Free Windows Admin Tool Kit Click here and download it now
February 23rd, 2011 3:49am

Hello Thanks for the reply i change the project target to a x64 and rebuilt the solution then i get the following error Could not load file or assembly 'WebApplication1, Version=1.0.0.0, Culture=neutral, PublicKeyToken=null' or one of its dependencies. An attempt was made to load a program with an incorrect format. i am not getting what to do.
February 26th, 2011 4:25am

Hi Bhavik, Sorry, I forgot to say you need to set project target to Any CPU or 64-bit if you are running on a 64-bit server in my first post. Incorrect format error is caused by an asp.net application has been compliled as a specific bit, but the bit that doesn't match that which IIS is running at. Do your server a 64-bit or 32-bit server? 64-bit applications couldn't run in 32-bit os. And it seems that your are running on a 32-bit os. So it is not the compatible problem and no need to configurate project target. Have you checked your permission on database and ensure the user is a menber of the groups mentioned in my first post? Thanks & Regards, Emir
Free Windows Admin Tool Kit Click here and download it now
March 1st, 2011 12:59am

hello seems like you try to retrieve data from Sharepoint using object model, i.e. by referencing Sharepoint assembly in your MVC application and compile it. It will work only if MVC application and Sharepoint server are located on the same web server. If you want to retrieve data from Sharepoint site which is located on another web server you need to use Sharepoint web services. So probably even if you will solve the problem "Web app not found" (which is caused in most cases by incorrect build configuration), you will need use another approach in real environment.Blog - http://sadomovalex.blogspot.com CAML via C# - http://camlex.codeplex.com
March 1st, 2011 2:33am

hello seems like you try to retrieve data from Sharepoint using object model, i.e. by referencing Sharepoint assembly in your MVC application and compile it. It will work only if MVC application and Sharepoint server are located on the same web server. If you want to retrieve data from Sharepoint site which is located on another web server you need to use Sharepoint web services. So probably even if you will solve the problem "Web app not found" (which is caused in most cases by incorrect build configuration), you will need to use another approach in real environment. Blog - http://sadomovalex.blogspot.com CAML via C# - http://camlex.codeplex.com
Free Windows Admin Tool Kit Click here and download it now
March 1st, 2011 10:31am

This topic is archived. No further replies will be accepted.

Other recent topics Other recent topics