p2p.wrox.com Forums

p2p.wrox.com Forums (http://p2p.wrox.com/index.php)
-   BOOK: Beginning SharePoint 2010 Development (http://p2p.wrox.com/forumdisplay.php?f=583)
-   -   Chapter 5:Access List with Server-side object Modle (http://p2p.wrox.com/showthread.php?t=80469)

yueyao_xu August 11th, 2010 10:57 PM

Chapter 5:Access List with Server-side object Modle
 
I did the "TRY IT OUT" section(Page 164).
But I got a FileNotFoundException on SPSite site = new SPSite(""),
and it side that "using http://XXXXX:XXXX can not find a Web application".

I use Administrator and did on the Sharedpoint Server.

please hlep me!!!

dloker August 13th, 2010 09:10 AM

Are you putting a valid sharepoint site into the Site URL: field?

yueyao_xu August 15th, 2010 04:23 AM

Quote:

Originally Posted by dloker (Post 261749)
Are you putting a valid sharepoint site into the Site URL: field?

Thanks for your response.

I use a URL that can access to sharepoint site with IE.

misken August 17th, 2010 08:54 AM

Quote:

Originally Posted by yueyao_xu (Post 261658)
I did the "TRY IT OUT" section(Page 164).
But I got a FileNotFoundException on SPSite site = new SPSite(""),
and it side that "using http://XXXXX:XXXX can not find a Web application".

I use Administrator and did on the Sharedpoint Server.

please hlep me!!!

i had the same problem, took me a few hours of problemsolving til i realized the solution:
1.go to project properties
2. build tab
3. target machine: 64x

worked like a charm for me, hope this helps.. no exercises in chapter 5 worked for me without a few hours of problemsolving

dloker August 17th, 2010 09:56 AM

That fixed it for me as well - don't know why the app had to be targeted specifically for x64, but then again, we're only running this on x64 boxes and the normal code production is set for x86.

misken August 18th, 2010 01:57 AM

Quote:

Originally Posted by dloker (Post 261922)
That fixed it for me as well - don't know why the app had to be targeted specifically for x64, but then again, we're only running this on x64 boxes and the normal code production is set for x86.

that is because sharepoint server can only be run on 64x machines, the target machine has to be 64x when making a client-side code running towards it, while, when making code run with serverside object model i dont think u need to change it, but it took a while to realize it, and this information should of course be in a book for us newbies in sharepoint

yueyao_xu August 19th, 2010 03:52 AM

Quote:

Originally Posted by misken (Post 261917)
i had the same problem, took me a few hours of problemsolving til i realized the solution:
1.go to project properties
2. build tab
3. target machine: 64x

worked like a charm for me, hope this helps.. no exercises in chapter 5 worked for me without a few hours of problemsolving

it works now!
Thank you very much!!

cchiang12 November 11th, 2010 04:57 PM

Thank you Misken, I would have never figured that out... (the 64x thing).

I also noticed that I have to create the list called Products first with 3 fields in it.... I don't think the book mentioned it---edit: just look at it again, it did mention the list before the example. Maybe it should cut that and paste into the example as step 1.

dloker November 11th, 2010 05:02 PM

The author has created an errata list - if anybody is going through the examples, it's a good idea to check it out to see what's needing correction. Check him out at:

http://blogs.msdn.com/b/steve_fox/ar...oint-list.aspx


All times are GMT -4. The time now is 06:29 PM.

Powered by vBulletin®
Copyright ©2000 - 2020, Jelsoft Enterprises Ltd.
© 2013 John Wiley & Sons, Inc.