Questions tagged [sharepoint-clientobject]

API to interact with SharePoint data remotely from script that executes in the browser

Source: Client object model resource center | SharePoint 2010: The new .NET managed, Silverlight, and ECMAScript (JavaScript, JScript) client object models in SharePoint Foundation provide powerful ways to interact with SharePoint data remotely from script that executes in the browser, from Silverlight applications, or from .NET client applications. These APIs include a subset of the features available in the server object model, providing access to objects at the site-collection level and lower within the SharePoint hierarchy.


SharePoint 2013 client APIs provides SharePoint client object model to retrieve, update, and manage data in SharePoint 2013. SharePoint makes the object model available in several forms:

  • .NET Framework redistributable assemblies
  • JavaScript library
  • REST/OData endpoints
  • Windows Phone assemblies
  • Silverlight redistributable assemblies

synonyms: client-object-model

281 questions
0
votes
1 answer

Alternative for EnsureUser in SharePoint client object model

I need to get LookUpId of a user in SharePoint 2010 using client object model. I am able to get it using EnsureUser method, but this method adds the user to the SharePoint web site if the user is not available to the site.My requirement is get the…
san
  • 304
  • 4
  • 20
0
votes
1 answer

Azure worker role.Sharepoint client sdk

I am using azure worker role and sharepoint 2013 client components to access sharepoint lists and process them. It works on development environment but when i upload to azure cloud service. It cannot create clientcontext. and I get the…
0
votes
0 answers

Invalid File Name error when loading lists from SharePoint 2013 with Client Object Model

One of our clients gets an error from SharePoint (2013) with our tool when it tries to load the lists from the SharePoint site. Our tool uses the Client Object Model and it loads the lists with the following code: context.Load( …
Carl
  • 1,224
  • 2
  • 19
  • 35
0
votes
0 answers

Sharepoint unit testing using fakes framework

I have an application which uploads a file to SharePoint via client object model. Now I need to write unit test cases for this application. The problem is, I how do I write test cases for the scenarios when a folder exists a folder does not…
Aditi
  • 1,188
  • 2
  • 16
  • 44
0
votes
2 answers

Unable to upload files in share point folders

I am using the following code to upload files in share point folders. Dim lobjSourceFileCreateInfo As New FileCreationInformation() lobjSourceFileCreateInfo.Content = System.IO.File.ReadAllBytes(lstrSourceFilePath) …
Rupesh
  • 983
  • 3
  • 11
  • 20
0
votes
1 answer

Able to create folder but cannot upload files in sharepoint 2010 Client object model

I am using sharepoint 2010 client object model to create folders and uploading files. I am able to create the folders but when I try to upload a file I am getting "401 unauthorized error". below is the code snippet. Try Dim…
Rupesh
  • 983
  • 3
  • 11
  • 20
0
votes
1 answer

SharePoint 2010 SP.FileCreationInformation() in javascript client object model

I try upload document to sharepoint document library using JCOM, but I have problem with metadata: brower console say "TypeError: SP.FileCreationInformation is not a constructor" and give link on "this.fi = new SP.FileCreationInformation();" …
KewinAstro
  • 1
  • 1
  • 2
0
votes
2 answers

Error with sharepoint client object model

I got the following error while running SharePoint ClientObject Model. I went through my code and checked if I missed any thing to load, but didn't see. "Process is Terminated: The property or field has not been initialized. It has not been…
Sawlah
  • 1
  • 1
  • 1
0
votes
1 answer

How to remove a NavigationNode in sharepoint online 2013 with CSOM

I want to remove a navigationnode (Not disable QuickLaunch) from Navigation sharepoint online 2013 ClientContext context = ClaimClientContext.GetAuthenticatedContext(targetURL, 600, 600); NavigationNodeCollection collNavNode =…
Hoang Tung
  • 23
  • 1
  • 6
0
votes
1 answer

Add an existing WebPart Using the Sharepoint client object Model

My knowledge of the Client Object model is fairly limited, although I have been able to remove and move existing web-parts on a particular page. But I'm now struggling to find and then add a custom web part programmatically using the SharePoint…
Paul
  • 1,103
  • 1
  • 13
  • 18
0
votes
0 answers

SharePoint upload issue

I'm working on existing web application where users fill out some forms and upload files. When the application is submitted the files are synced with SharePoint site. The upload code is below. // Upload files to the Document Set. for (int i = 0; i <…
sakura-bloom
  • 4,524
  • 7
  • 46
  • 61
0
votes
1 answer

Sharepoint 2010 - Client Object Model - ContentTypeId keeps reverting back to original

first off: big fan of this site and have always found a solution to a problem when visiting here. I have a small problem when using the Client Object Model for Sharepoint 2010: I am trying to set the Content Type of an item, however it keeps…
0
votes
1 answer

Adding list items using the Client Object Model

I'm currently working on a Windows application to be used to migrate data from a legacy system into a SharePoint list. To do this I am accessing the Client Object Model and using it to create new list items and update the relevant field values. The…
0
votes
1 answer

Retrieving Start/End Time fields with SharePoint Client Object Model

I have some experience using the SharePoint Client Object Model to retrieve text fields and URLs/images from lists in SP 2013. I'm currently trying to do something similar with a calendar. I have been able to successfully retrieve Title and Location…
0
votes
1 answer

Process multiple sharepoint list items

in a SharePoint list view I would like to duplicate selected list items. My code works when only one item selected but fails, when more. Debugging the code I see that it goes through all selected items first before calls the success callback. Also…