API for interacting with SharePoint from .NET, Silverlight, and JavaScript.

learn more… | top users | synonyms (1)

1
vote
2answers
298 views

Given a URL, can I find if the site exists using the client object model?

I am looking for a "cheap" option to find out if a site exists, given a URL. I have no control over the server environment, so I am not able to add web services or code to it. Is there a way to find ...
0
votes
1answer
39 views

Newly added files to document library client object model

I am developing an application which is will be deployed in the client machine. Client will be downloading the applications from SharePoint to local machine to a fixed folder(folder wont get ...
1
vote
2answers
40 views

Get the field “Created”

I have a list "Consult", and I want get the field "Created" this is my code: function consultWorkOrder() { try { var customlist ; var clientContext = new ...
2
votes
1answer
66 views

How can I get a listing of all sites in my site collection using Client Object Model?

As the Site Collection Administrator, I don't have access to the servers to write server side code to get a listing of all sites in my site collection. I can write sandbox solutions in SP2010 to get a ...
2
votes
1answer
411 views

Load page error when I use ScriptLink in the page head

Here is the beginning of my custom SharePoint Application Page: <%@ Assembly Name="$SharePoint.Project.AssemblyFullName$" %> <%@ Assembly Name="Microsoft.Web.CommandUI, Version=14.0.0.0, ...
2
votes
2answers
180 views

Field or Property 'Url' does not exist

Can someone help me understand why I am unable to get the "Url" property from this example? I get the error "Field or Property 'Url' does not exist": ClientContext ctx = new ...
5
votes
1answer
190 views

SharePoint Client Object Model not returning hidden folders in document library

I am using the SharePoint Client Object Model to get information from a SharePoint 2010 document library to be able to delete old htm-files located there. The problem is that these htm-files have ...
0
votes
1answer
116 views

Convert Person/User Group to String

I am retrieving a list that contains Persons and would like to convert them to String, and also be able to count how many users are per list. The Person is retrieved as an Object. How can I solve this ...
3
votes
1answer
332 views

Get distinct values via mechanism used when clicking “Show Filter Choices” on a Sharepoint list using Javascript

As many other people on this site seem to need, I'd like to get an array (or equivalent) of the distinct values in a field for a list. The canonical way of doing this is to retrieve the entire field ...
0
votes
2answers
435 views

Programatically update profile field(s)

I have a requirement to update user profile fields. I'm able to query the fields, of course, using the CSOM API in Javascript. But, as per here - ...
7
votes
1answer
820 views

Client Object Model SystemUpdate

I need to have the SystemUpdate functionality from the Client Object Model. Is there any way I can do it since the ListItem.SystemUpdate() does not exist? Another solution would be to disable the ...
7
votes
1answer
4k views

Get a value included from a lookup column using the JavaScript Client Object Model

Related: How to retrieve a ListItem using the Javascript Client Object Model? In my previous question I was able to successfully retrieve a basic value from a list item. My problem is that I am now ...
1
vote
3answers
2k views

Missing fields from SiteUserInfoList user ListItems

I'm using the SharePoint 2010 Client Object Model to retrieve all the users from a SharePoint instance, via Web.SiteUserInfoList: var query = new CamlQuery { ViewXml = "<Query/>" }; var ...
0
votes
2answers
1k views

get Library document URL using Javascript client object model

I am working with SP.js to get data from a SharePoint library. Below is the code i am using: var clientContext = new SP.ClientContext(); var oList = ...
2
votes
0answers
40 views

Client WebPart (apppart), I need to explain some settings

Property element <Property xmlns="http://schemas.microsoft.com/sharepoint/" Name="Text" DefaultValue="Text" Multilingual= "true" | "false" PersonalizationScope="user" | "shared" ...
0
votes
1answer
415 views

List Onload event

What I want to do: I have a custom list that contains a lot of items. When an user loads the list, all items of his view should be checked. If there is a special value in the listitem a notifiaction ...
1
vote
1answer
363 views

how to use the gridview in SharePoint 2013 Hosted App

I want know how to use the grid view in a SharePoint-hosted App. Can any one provide information on this?
1
vote
2answers
365 views

Exists / Count in client object model

What's a good way to perform an Exists or Count on the client object model classes? I have list with views. I want to check if a view already exists before creating it. Tried a couple of things, but ...
2
votes
1answer
3k views

Properties when uploading Files using REST in SP 2013

After a lot of research I finally got uploads via REST working in SharePoint 2013. But I would like to provide additional properties to the Add Function like Title. This code works so far but the only ...
3
votes
3answers
4k views

List API get all items limited to 100 rows

When doing a GET call to the List API from JavaScript: "/_api/web/lists/GetByTitle('ListName')/items" the results returned are limited to 100 rows. Is there any way to return more rows in the result, ...
1
vote
1answer
943 views

Not able to fetch Term store and related terms using client object model

I want to fetch termstore, Termsets and related terms.However, Iam not even able to fetch the termstore. Below is the error message. TypeError: termStores is undefined termStoresEnum = ...
0
votes
0answers
85 views

Update a rating scale field of survey list using JavaScript

I have created a survey list which has 3 columns. One column is of type rating scale with value 1-5 . Using JavaScript I'm able to update the first two columns. But not able to do so for the rating ...
3
votes
2answers
708 views

Accessing files in SharePoint AutoHosted App 2013

I am creating an AutoHosted App in SP 2013 and trying to access the file under one folder of the remote Web (need to pick the file from current project directory location and pass that file to another ...
0
votes
0answers
96 views

SharePoint Online and execute query async

The code below is running in a Silverlight XAP which is using the SharePoint Silverlight client object model. The application logical flow is the following: first, a file is uploaded in extension ...
3
votes
3answers
6k views

How to get Item from ListItem with Client Object model

I'm trying to printOut some items from a ListItem. But when run the code I get following exception: "Invalid usage of query execution. The query should be executed by using ExecuteQuery method on ...
0
votes
2answers
176 views

Accessing template properties for a collection of sub webs using the ECMA Client OM

I am doing a Sharepoint project where I am displaying all subsites in a list on the home screen. I have set them up in a Microsoft Metro/Tiles design, so that each subsite represent one tile. I am ...
0
votes
1answer
70 views

Date functions with $select in REST API

I'm using the following REST call to get the data. Here is the url structure: SiteURL+'/_api/web/lists/GetByTitle(\''ListTitle+'\')/items?$select=AlternateThumbnailUrl,Title,Created this is ...
0
votes
0answers
49 views

Extracting blog posts with images using Client Object Model

I'm extracting blog posts from SharePoint 2010 with the managed client object model in order to migrate the data onto another platform. I can get both pictures and posts from the blog but I can't find ...
2
votes
2answers
589 views

When using Sharepoint Client Model I get error : The 'Contains' member cannot be used in the expression

When using 'Contains' in Linq query: var camlQuery = new CamlQuery(); var listItems = list.GetItems(camlQuery); var itemQuery = listItems.Where(i => ...
0
votes
1answer
917 views

Client Object Model to Retrieve UserProfileAttribute

we can get directly user information by using Server object but how to get this by using Client object model ?
1
vote
4answers
758 views

Check user existence on SharePoint

I deleted a user in Users and groups management of Office 365. But his information is still in Site Collection's All users. How can I check if a user was deleted or not? Using Client Object Model.
1
vote
2answers
2k views

How to apply CAML in SharePoint view

I'm using SharePoint client object model and trying to query specific view but not getting the correct method to do so. Here is my code, using SP = Microsoft.SharePoint.Client; using ...
1
vote
2answers
1k views

Upload to DocLib with jQuery (and REST) without HTML5

Uploading Documents to SP 2013 with jQuery and REST work just fine (Properties when uploading Files using REST in SP 2013) but these methods require a HTML5 compatible browser. The problem is now I ...
0
votes
0answers
36 views

Batch retrieve document information via c#

Note: Using Microsoft.SharePoint.Client Greetings folks, I've written a system for automatically updating some tools we use (tools are excel workbooks, but immaterial to discussion). Part of this ...
0
votes
1answer
2k views

SPDiagnosticsService.WriteTrace throws error “Object reference not set to an instance of an object”

I am trying to write entries into logging and have trouble doing so. Using Client object model on SharePoint foundation. Code is running from a console app. SPDiagnosticsService.Local.WriteTrace(0, ...
0
votes
2answers
353 views

Jquery to display date in MM/DD/YYY in sharepoint client object model [closed]

In My sharepoint list i have a Duedate if type DateTime.Using Client object model when we fetch the value from this Field, it is displayed in the below format(Mon Jun 23 GMT+0530 2014).How to convert ...
1
vote
2answers
449 views

Control JavaScript with Ribbon Button

my aim is to add a Ribbon Button which is opening a printing dialog for a selected file in a document library. I already added the Button with SP Designer and linked it with a html file which is ...
1
vote
2answers
2k views

Get all subsites of top level site using JavaScript OM

I am trying to get all sub sites of the top level site. However, the code I wrote for the app returns zero subsites. I am a little mystified as to why: var context = SP.ClientContext.get_current(); ...
0
votes
2answers
253 views

Delete column from list using Client Object Model

Developing for SharePoint Online, I've created a Contact List programmatically in my app. I now want to delete some of the columns that were added to the list. So I have the following code: var ...
1
vote
0answers
426 views

CSOM caml query list view lookup threshold

I have a list with about 15 managed metadata columns in it. Now I want to query that list using CSOM. I don't want to retrieve all the columns values so I limited the column values retrieved by using ...
0
votes
2answers
197 views

Load more list items on scroll

I am showing the first 5 list items on the page (in one div). Div has vertical scroll bar. I want to show the remaining 5 items on when scroll goes down end. I am using CSOM to fetch list items. Any ...
0
votes
1answer
941 views

CSOM Javascript - when executing query on multiple lists getting error - SharePoint 2010

Is here any SharePoint expert, who can help me find out, why I am getting error on lists queries? I am trying to fetch data from multiple list asynchronously, but I am getting following error: The ...
8
votes
5answers
7k views

Creating Nested Folders via Client Object Model

I'm trying to create nested folders in my document library so it looks like this: http://site/PublicDocuments/Folder1/Folder2/Folder3/ The document library "Public Documents" exists but none of the ...
1
vote
2answers
460 views

Calendar View not properly displaying in WebPart

I'm trying to have my events list display as a calendar view in a Sharepoint-hosted app written using JavaScript and the Client Side Object Model. Here's the code I'm using. From Default.aspx: ...
0
votes
1answer
85 views

Unable to add .exe file to SharePoint 2010 using Client Object model after it has been removed from blocked files list

Language: C# Framework: .Net 4.5.1 Environment: SharePoint 2010 - Windows Server 2008 R2 My software is used to upload files to sharepoint. It works perfectly well for the majority of files. However, ...
3
votes
2answers
8k views

SPService GetListItems with CAML : can't get example to work

enter code hereI am using an example I found on codeplex of SPServices with CamlQuery to try to get list item values with where clause on the ID. For whatever reason this doesn't seem to work for me; ...
1
vote
2answers
585 views

JS CSOM to redirect to another SharePoint URL

I have an application page which takes some inputs for list creation. Based on these inputs, i am using JavaScript Client Object model to create a new list. Once the list is created a notification ...
0
votes
2answers
194 views

Javascript Client Object Model Update List Items (only some items updating)

I am using a JavaScript button to set a Field-2 on each selected list item from "false" to "true". It first checks if Field-1 is empty, and if it is, sets Field-2 to true. The relevant code is as ...
0
votes
2answers
170 views

Get SP.ListTemplateType enum value using JSOM

I am trying to create a new list (based on a dropdown menu selection) using JavaScript Client Side Object Model. var typeList = "SP.ListTemplateType." +listTemplateType; ...
2
votes
1answer
588 views

set or update multiple values cascading lookup field using client object model

I'm struggling since a couple of weeks with setting a multiple values cascading lookup field using a client object model, I could set the first value but then It show me an error of invalid lookup ...