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

learn more… | top users | synonyms

2
votes
1answer
612 views

SharePoint 2013: Creating custom list in SharePoint using CSOM

I'm having a difficult time creating custom lists using the SP JS API. Here's what I'm attempting to do: var lciTasksList = new SP.ListCreationInformation(); lciTasksList.set_title('ProjectTasks'); ...
0
votes
1answer
23 views

Can I [safely] change the code name/EntityPropertyName of objects?

We have several lists and columns that we've renamed overtime, and some of the lists/columns also contain spaces. This makes accessing these objects with the EntityProperytName through the CSOM quite ...
1
vote
2answers
5k views

CSOM move the files one folder another folder

I have to all files from one folder another folder using CSOM and C# Thanks for your replay Huge Wood my code is below var targetSite = new Uri("https://hello.com//teams/Worldwide_Site"); ...
0
votes
1answer
135 views

Sharepoint define search scope using csom

I have a sharepoint installation with multiple site collections, let's say siteA, siteB e.t.c I am using the following code to search in sharepoint using (ClientContext context = Connect()) ...
1
vote
1answer
165 views

Get Sharepoint Permissions\Roles (custom) of a user from AD Group that is part of SP Group via CSOM

SharePoint 2013 + provider-hosted app. User is part of AD group. AD group is part of Sharepoint group. Sharepoint group has custom security permissions assigned. How do I check whether user has some ...
1
vote
1answer
25 views

How to change a list URL via JSOM?

I'm trying to make a JSOM utility that will allow me to alter the properties of pre-existing document libraries. So far I have successfully managed to update the list 'Title' and 'Description' ...
0
votes
2answers
30 views

Deleting items in object-model

How to add a new item to SharePoint list in server object-model using C#. This is my code and I want to delete just one item using listBox SPWeb web = SPContext.Current.Web; ...
0
votes
0answers
31 views

Is it possible to simply enable incoming email and set the email address using SharePoint 2013 JavaScript Object Model (JSOM)?

I know this can be done with C#, but I am restricted to a client (JSOM) only environment. I already looked at all the properties and functions of the SP.list (oList in the code below) object using the ...
0
votes
0answers
80 views

Set value of summary links column using CSOM in SharePoint 2013

We are creating a custom page where we are providing user a control to add summary links. This is a provider hosted app page and we can't use the SharePoint controls there. So, we are giving the users ...
1
vote
2answers
176 views

CrossListQueryInfo or SPSiteDataQuery equivalent in REST API or CSOM

Is there any equivalent in SharePoint 2013 RESTful API or JavaScript Object Model to either one of the following? CrossListQueryInfo SPSiteDataQuery
1
vote
1answer
346 views

Sharepoint 2010 CSOM Get user and his groups by login name

I want to get a user and all his groups by a login name. Easy to do in Sharepoint 2013. clientContext.Load(site, l => l.RootWeb.SiteUsers, l => l.RootWeb.Id, l => l.Id); ...
0
votes
1answer
124 views

updating list item of a file using CSOM

I am using following code to copy a file from a Document Library to another. The file is copied and is there, but the fields will not be updated. fileInfo = File.OpenBinaryDirect(srcClntCntxt, ...
0
votes
3answers
326 views

JSOM default groups when creating subsite

function createWebsite(siteName, site) { this.clientContext = typeof site !== 'undefined' ? new SP.ClientContext(site) : SP.ClientContext.get_current(); this.oWebsite = ...
5
votes
2answers
3k views

Datetime update is one day off

I'm updating a list with a date field (just the date) using the ECMASCRIPT object model but when the date is inserted is one day off from the introduced date, It's literally making me pull my hair off ...
0
votes
0answers
66 views

Ribbon button added via CSOM is disabled on publishing page in SharePoint 2013

We have added a custom action in the publishing page ribbon using CSOM in SharePoint 2013. The issue is this action is disabled and i can't click on it. The strange thing is it works on one site and ...
0
votes
0answers
102 views

How to get Structured Navigation on publishing SharePoint Site with CSOM

I am trying to re-create my Top navigation bar in a provider hosted MVC App. my C# public static NavigationNodeCollection GetNav() { if (HttpContext.Current != null) { ...
0
votes
1answer
34 views

Equivalent of SPRelativeDateTime.GetRelativeDateString in CSOM sharepoint 2013

What is the equvalent API for SPRelativeDateTime.GetRelativeDateString in sharepoint 2013 Client object model using (SPSite site = new SPSite("http://your.site")) { using (SPWeb web = ...
2
votes
2answers
421 views

Setting value of Enterprise Keywords using CSOM

I have included the enterprise keywords column in my contenttype and list and I try to set the value using the managed CSOM. I just used the default already existing column so the column name is ...
2
votes
1answer
39 views

How to Send return value to the caller function correctly

Hi i have a code like this. var guiD = myCallerFunction('abc'); alert(guiD);====>Line No Y function myCallerFunction(name){ //Some code here var terms = termSet.get_terms(); ...
2
votes
1answer
47 views

SharePoint Online: Change properties

I am retrieving a change log for SharePoint Online site, but I am particularly interested in the who performed the change and on what item. $changeQuery = New-Object ...
1
vote
1answer
72 views

Get GUID by term name - jsom

i need to pass term name as a parameter and return the GUID of that particular term. As an example if i pass My Term 1 it should return GUID of My Term 1. var termGuid=getTermByName('My Term 1'); ...
0
votes
1answer
43 views

Sharepoint online 2013, Move term to another branch (parent)

In Sharepoint online we can move Term manually. I need that to be done programatically using JSOM. Does anyone have code for that? I checked ...
0
votes
1answer
721 views

Copy ListItem from one list to an other by ribbon custom buttom

I try to create a new button in the ribbon. When the person select a list item and click on this button this item will be copied to another list. CommandAction=""javascript: var context = ...
0
votes
1answer
192 views

Fields validation with Javascript in custom WebPart - SharePoint Online -

I'm currently developing a SandBox WebPart for SharePoint Online (2013) which have two TextBoxes. I'm trying to add the following code for validate the Email and Subject TextBoxes once the Button ...
2
votes
1answer
690 views

Problem storing SharePoint context in Provider hosted app hosted in a azure website

I created a provider hosted app, which I want to deploy in a azure website. The problem that I'm currently facing is that I don't have a SharePointContext after postback. I'm using the default way to ...
0
votes
2answers
41 views

Sharepoint2013 ctx and Js : Retrieve the value of a field from a list

I'm a totally beginner and totally stuck to a point in my Sharepoint project. What i would like to achieve: part 1 : retrieve the current user's Department's name part 2 : retrieve the department's ...
0
votes
1answer
35 views

Query “Standard View, with Expanded Recurring Events” doesn't show all items

For Calendar list, I have created a view with type of "Standard View, with Expanded Recurring Events". This view is used to show each instance of a recurring event. So if there is an event with let's ...
0
votes
2answers
178 views

JSOM function undefined in SharePoint - Display list view items

I am using the following code to get the available items from a list view. <script type="text/javascript" src="http://ajax.googleapis.com/ajax/libs/jquery/1.7.1/jquery.min.js"></script> ...
0
votes
3answers
273 views

PeoplePicker using JSOM

Hi is there anyway to manipulate PeoplePicker using JSOM. How tho get or set value of PeoplePicker using JavaScript
0
votes
1answer
284 views

how to call executeQueryAsync() to behave synchronously?

Items are saved in jumbled bcoz I am using executeQueryAsync().How to make executeQueryAsync() behave synchronously?
0
votes
0answers
40 views

Display Rating Stars

I have a page and I want to display the items' title of a list with the rating stars for each item beside it in that page. What should I do?
0
votes
1answer
25 views

reuseTerm JSOM usage

Anyone familiar with SP.Taxonomy.TermSetItem.reuseTerm(e, d) ? It's there in MSDN and I guess it is to copy a termset to another termset as a sub-term. Any idea?
0
votes
0answers
26 views

Term ID by Term name JSOM

I need to do something like this. var termID=getTermIDByTermName('My term Name'); function getTermIDByTermName(name){ var ctx = SP.ClientContext.get_current(); var taxonomySession = ...
0
votes
0answers
79 views

CSOM retrieve List Item doesn't show some Lookup Key Value pairs

I try to load a ListItemCollection from my SiteCollection using CSOM C#. Therefore I use the following List rr = web.Lists.GetByTitle("MyTitle"); context.Load(rr); FieldCollection fcol = rr.Fields; ...
0
votes
0answers
39 views

Export/Import SharePoint List Template without using Microsoft.SharePoint.dll (Is it possible?)

What I'm trying to do is build a migration tool that when moving from a development environment to production environment for example, any SharePoint List references will be packaged as List Templates ...
1
vote
1answer
158 views

Does audiences work with CSOM?

If we build an SharePoint app and need to show items based on audience targeting, can we use CSOM for that? Can't find any references to it in the CSOM SDK.
0
votes
0answers
27 views

Moving a term to another parent termset JSOM

Hi i need to Move My Term 3 term under My Term 1 (need to make My Term 3 as a child term of My Term 1) using JSOM. I tried many code snippt but i was really unable to do that. Anyone else has tried ...
0
votes
0answers
22 views

Sharepoint 2013 - jcom - How to add function and increment 1 to a specific field?

The following setup is working perfectly for fetching data from my custom list... var items; $(document).ready(function () { SP.SOD.executeFunc('sp.js', 'SP.ClientContext', CustomAction); }); ...
0
votes
2answers
195 views

Add hyperlink to Sharepoint list item

I need to add a hyperlink to the Sharepoint (2013) list item in one of the columns or make the list item itself as a link. I don't know how to do this. Any help is appreciated!
1
vote
1answer
46 views

SharePoint 2013 - JavaScript - List Data fetch failed

I'm using the following to read data from a custom list in SharePoint 2013: var items; $(document).ready(function () { ExecuteOrDelayUntilScriptLoaded(CustomAction, "sp.js"); }); function ...
0
votes
0answers
56 views

Unable to get the list of all SP2010/SP2013 Work Flows (OOTB and SPD) which are associated with a List using CSOM

We came across an issue while pulling the workflow associations of lists, CSOM and Splist.WorkflowAssociations will not list the workflows created through SPD and attached to list. If anyone faced ...
0
votes
1answer
42 views

AverageRating is null in JSOM

I am trying to get the rating field from a SharePoint pages library in JavaScript, after using the get_item('AverageRating') it's returning null. My function looks like the following: var ...
1
vote
1answer
186 views

SP.SOD.loadMultiple Issue

I am trying to load the project context in order to access some data. I am using the SP.SOD.loadMultiple function as follows: SP.SOD.loadMultiple(['sp.core.js', 'sp.runtime.js', 'sp.js', 'ps.js'], ...
1
vote
1answer
195 views

Enable like function from catalog page via javascript object model - improve this?

The business need is to create a 'channel' page that will display thumbs of videos like a gallery, and I need to enable people to 'like' that content from the gallery page. (Standard disclaimer: I'm ...
0
votes
1answer
44 views

Creating client side solutions

i hear people say they want to create client side solutions in visual studio, would that be applicable in the case of visual web part? if i create a visual web part and only write javascript code in ...
1
vote
0answers
48 views

Move terms to another termset/ termstore JSOM

Hi i need to create an app which gets two inputs 1.) Term name 2.) Parent name( term-set or term-store name) once i click on a button, that 1.) term should go under 2.)parent term-set If i put ...
-1
votes
1answer
30 views

CSOM - setting the custom list name, when attempting to receive list data

With the following code, how do I know what list I am retrieving data from? var siteUrl = '/sites/MySiteCollection'; function retrieveListItems() { var clientContext = new ...
0
votes
1answer
98 views

BCS Managed Client Code Get all method instances

When using the class Microsoft.BusinessData.MetadataModel.Entity entity; does anyone know how to get all the External Content type operation method instances so i can dynamically pass the value to ...
1
vote
2answers
108 views

How to get termstore GUID by giving its name

I've a term-set called My Term Set, I need to get the Unique Identifier by passing its name. How can i do that? This is the code i have tried so far but it gives undefined Please help me thanks a ...
5
votes
4answers
7k 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, ...