locked
How to Programatically upload data from XLS to Sharepoint site RRS feed

  • Question

  •  

    How to Programatically  upload data from XLS to Sharepoint(2007) site through Lists.ASMX web service. When we try to access the web service, no response is received. Pl. let me know if the sharepoint port is open for programatic access. If not, how do we access share point site through programs?

    Friday, October 19, 2012 4:43 AM

Answers

  • Hi,

    >When we try to access the web service, no response is received

    If you don't have read access on site then you can not use lists.asmx service directly but you also have option to pass authentication when access this site. This is line where you actually use default or can pass username and password and domain name in that.

    /*Authenticate the current user by passing their default
    credentials to the Web service from the system credential cache.*/
    listService.Credentials =
    System.Net.CredentialCache.DefaultCredential

    Check this MSDN article to access list through service and update the item in list:

    http://msdn.microsoft.com/en-us/library/ms440289.aspx

    http://msdn.microsoft.com/en-us/library/lists.lists.updatelistitems.aspx

    Hope it could help


    Cheers, Hemendra-MCTS "Yesterday is just a memory,Tomorrow we may never see"

    Friday, October 19, 2012 10:30 AM
    Moderator

All replies

  • Hi,

    >When we try to access the web service, no response is received

    If you don't have read access on site then you can not use lists.asmx service directly but you also have option to pass authentication when access this site. This is line where you actually use default or can pass username and password and domain name in that.

    /*Authenticate the current user by passing their default
    credentials to the Web service from the system credential cache.*/
    listService.Credentials =
    System.Net.CredentialCache.DefaultCredential

    Check this MSDN article to access list through service and update the item in list:

    http://msdn.microsoft.com/en-us/library/ms440289.aspx

    http://msdn.microsoft.com/en-us/library/lists.lists.updatelistitems.aspx

    Hope it could help


    Cheers, Hemendra-MCTS "Yesterday is just a memory,Tomorrow we may never see"

    Friday, October 19, 2012 10:30 AM
    Moderator
  • Hi,

    Have you resolved you problem? If yes then please provide your solution so other can take benefit of that and if above post help you to resolve your problem then mark it as answer.


    Hemendra: "Yesterday is just a memory,Tomorrow we may never see"

    Whenever you see a reply and if you think is helpful, click "Alternate TextVote As Helpful"! And whenever you see a reply being an answer to the question of the thread, click "Alternate TextMark As Answer

    Friday, November 16, 2012 10:18 AM
    Moderator