Menu
Cutty
  • Chryslers
  • Lutherie
  • YLSNED
  • About
Cutty

Getting List Items from SharePoint list

Posted on October 26, 2010February 18, 2015 by Iain 'Cutty' Carlin

Today I am trying to populate an ASP.Net drop down list from the contents of a SharePoint list using the Lists web service.

I found this Microsoft page that was most useful in helping me to do that: http://msdn.microsoft.com/en-us/library/lists.lists.getlistitems.aspx

A couple of issues I struck that are mentioned in the article:

  • I was getting a SOAP error saying “Guid should contain 32 digits with 4 dashes”. As mentioned in the above article this is due to Visual Studio putting a web reference in Web.config to the top level site rather than the sub-site in which the list exists.
  • Once the above was fixed, I got a second error: “InvalidOperationException: Client found response content type of ‘text/html; charset=utf-8’, but expected ‘text/xml’”. Turns out when I fixed error 1, I put a space in the URL to the web service! Doh!

 

  • SharePoint
  • Recent Posts

    • Books I read in 2025
    • 2024 was the best year for our solar system
    • Books I read in 2024
    • Books I read in 2023
    • Happy New Year 2024

    Categories

    • Chryslers (1)
    • Cutty's Blog (13)
    • Lutherie (38)
    • You Learn Something New Every Day (44)
    ©2026 Cutty | Powered by Superb Themes