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

learn more… | top users | synonyms (3)

0
votes
0answers
178 views

Update Custom Field in Task Level Project Server using JSOM (PS.js)

Does anyone have javascript which updates the task level custom field? I just have the code with C#. I am trying to convert this code (below) to javascript and use it. DraftProject projCheckedOut = ...
0
votes
0answers
60 views

SharePoint-Hosted App check if folder exist in HostWeb

This is wierd, i have created a folder in site asset programmatically by JSOM. Then i created a function to see if my folder exist or not (In the GUI its visible). My function returns null but if i ...
0
votes
0answers
32 views

Edit list Email Alias via CSOM

I am trying to set a list's email alias via CSOM and can't seem to find a way to do it. I can do it in powershell via the .EmailAlias property and I can also set that same property if I were writing ...
1
vote
2answers
267 views

Get list default view url in SharePoint JSOM Client Object Model

I have simple JSOM script to get all the list and it's default view url but i am not getting default view url property var context; var lists; // This code runs when the DOM is ready and creates a ...
1
vote
1answer
82 views

How are Deferreds different from callbacks

I have following piece of SharePoint JavaScript client object code which works perfectly without throwing any error. $(document).ready(function () { //don't exectute any jsom until sp.js ...
0
votes
0answers
47 views

Using SP.UserProfiles.PersonalSiteInstantiationState

I am attempting to check a User's MySite status by utilizing sp.js to return the following enumerations. I have had success using the People Manager & Person Properties objects, but not the User ...
0
votes
0answers
279 views

SP2013 - The object is used in the context different from the one associated with the object

I have a function that initializes a custom taxonomy control, as below (not in myControl.js) function initMyControl() { if (something is true) { var context = new ...
1
vote
2answers
62 views

How to retrieve a file by UniqueId in any List subfolder

I would like to get a file by UniqueId inside of a List. I am not guaranteed which folder the file will be in so I'm using the List.GetItems call and using a CAML query to only pick the file that ...
0
votes
1answer
58 views

2013 MySite - WebPart provides user properties

I'm currently branding a 2013 MySite host and to do so I access some user information via JSOM. EnsureUserProperties: function (callback) { /// <summary> /// Ensures that the ...
0
votes
0answers
124 views

N number of call for /_vti_bin/client.svc/ProcessQuery

I have on application page which will display data from list. For that I have write client object model code which is as follow: var PageList = _spPageContextInfo.siteAbsoluteUrl + '/xxxx'; ...
1
vote
1answer
243 views

Field names in announcement list in Sharepoint Online

I am trying to add fields to an announcement list. I have successfully added various fields with single-word names: announcementy.Fields.AddFieldAsXml("<Field Type='User' ...
0
votes
1answer
40 views

Index out of range, when context.ExecuteQuery(). While creating the Taxonomy

I am writing a provider hosted app. In this I am trying to create taxonomy group and then multiple term sets. The first set gets created successfully but the second time in the foreach loop, ...
1
vote
0answers
33 views

Cannot update allowMembersEditMembership

I can't seem to update the setting on a group to allow members to edit members. This is my code: function setGroupsMembershipEditingMode(uri) { var context = new SP.ClientContext(appweburl); var ...
1
vote
1answer
222 views

How to write a WCF Service for SharePoint 2013 hosted App?

I've deployed a WCF Service in SharePoint. I am able to retrieve data from it using URL: http://nit-hv8-itr4:1111/_vti_bin/PresidentsService.svc/GetAllPresidents The problem occurs when I try to ...
2
votes
1answer
109 views

Get before properties in itemupdated event via CSOM in a RER

Can I get the before properties in item updated? I need to check if a field changed its value, between the previous and the new value in a RER with CSOM. The following code tell me the ...
1
vote
2answers
232 views

How to itetrate through files in a document library

I've been creating a provider hosted app and I'm stuck at retrieving Documents titles using CSOM C# my code is as follows. var spContext = ...
1
vote
1answer
837 views

Reading SharePoint Document Library File names using CSOM

I am trying to read the file names from SharePoint document library. I have uploaded some files and created some folders on the site. I get the ItemCount number. But when i try to get the File count ...
1
vote
1answer
382 views

Assigning Folder Permissions with JSOM

Is it possible to use JSOM to assign unique folder permissions? I found the SP.BasePermissions.set() method but can't seem to find much documentation on it. Much more out there using C# but ...
3
votes
1answer
97 views

Background tasks/timer jobs in SharePoint O365 with Azure provider-hosted app

I am building a provider-hosted app for SharePoint (O365) which is hosted in Azure. I do all of my logic through CSOM, more specifically using an MVC web project. At the moment, I have some branding ...
1
vote
2answers
112 views

Javascript always failing

I am busy writing some javascript to take a list of selected documents and do some processing on a list with each document in Office365. I am getting a strange error when the code tries to load the ...
1
vote
1answer
88 views

Issue in REST call

I have two methods which will be call on bashed on condition Code: //Method to add item in TT items list. function addTTItemsList(url, listname, itemTitle, columnOrder, rowOrder, listName, ...
3
votes
1answer
184 views

Checking CSOM people editor value

How can we check the user entered key in Client people editor is user or group? I have created a people editor in CSOM. I can save the value to the list successfully. But before saving i need to ...
1
vote
1answer
496 views

O365: Unable to get property 'get current' of undefined or null reference

I'm on SP2013 in an O365 environment. I am trying to pull some data from a list and render that data using the Google charts API. I am doing this in a content editor web part that points to an HTML ...
0
votes
1answer
97 views

vb.net client object model: get wikipagelibrarytitle/list by url

I am using the .net client object model for SharePoint 2010. I am able to create a new wiki page in my wikipagelibrary using the following method: Dim wikiLibrary = ...
-2
votes
1answer
123 views

SharePoint WCF SOAP, Rest, AJAX [closed]

I need to know the following things: How is SharePoint used with WCF, REST and SOAP.
0
votes
1answer
139 views

Modifying folder contenttypeid via REST

I have a library where a customized SPFolder content type is defined. When I use the following code in generating the folder I'm perfectly able in creating one. However, I seem to be unable in using ...
0
votes
1answer
288 views

CSOM get items from subsite

I want to be able to retrieve items from a subsite. I've found some code which works but only on the current site. <script type="text/javascript"> ExecuteOrDelayUntilScriptLoaded(MainFunction, ...
0
votes
0answers
59 views

Using the client obeject model getting the multiple lines of text field append changes to the same text

I have a SharePoint List in site. It has a custom list. I added a new field with type 'Multiple lines of Text' and in Additional Column Setting section selected 'Append Changes to the existing ...
0
votes
1answer
46 views

Overide Core.js Options?

What is the best way to be able to manipulate objects in the DOM using JQuery/JavaScript, specifically in an InfoPath browser enabled form in SharePoint 2010? If I try to grab a value from an input ...
0
votes
0answers
81 views

Getting the version history of a list item

I am creating a content web part and one the list items is used with versioning. I want to show all the versioning on the page. Is there anyway to do this? maybe using CSOM or something
0
votes
0answers
67 views

Missing SharePoint Online Client Tenant Silverlight dll

I'm trying to find the microsoft.online.sharepoint.client.tenant.silverlight.dll to develop a Silverlight tenant control solution but I can't find it any where. It is mentioned specifically in the ...
0
votes
1answer
129 views

Get ctx based on list GUID

I want to get list ctx based on GUID. My requirement is to develop a context menu security webpart. I want to display the list/library context menu items in my application page which is user ...
2
votes
1answer
104 views

Difference between ViewFields and Include, in JSOM

I am working on a solution where I am using JSOM, I got confused on to the usage of Include in when you load the items collection, and usage of to get which fields you want? What's the specific ...
1
vote
1answer
249 views

SP2010: Client object model: add new wikipage to document library

Is it possible to create a new wiki page using the client object model and give it some content ("<h1>Welcome to the SharePoint!</h1>")? I'm using VB.Net
0
votes
1answer
231 views

Get user Login from User or Group field

I have a list with User og Group field. I've retrieved item from it, now I need to get user's Login. By reading User or Group field I can get only user id and account name. here's my code: var ...
0
votes
1answer
81 views

Deleting a single item from RecycleBin gives error “operation is not valid due to the current state of the object.”

I have below code , but it gives mentioned error on ExecuteQuery() after item.DeleteObject(). Site collSite1 = _ctx1.Site; RecycleBinItemCollection collRBI1 = collSite1.RecycleBin; ...
0
votes
0answers
159 views

Attach file to list item in SharePoint 2013 Sandboxed solution

I have developed a visual webpart in Sandboxed solution for SharePoint 2013/Online. I am trying to add an attachment to list item at the time of creating the item using Client Object Model. I have ...
0
votes
0answers
13 views

CSOM URL path length restrictions same as normal user operations through a browser or different?

I know SharePoint has a limitation of unencoded URLs of about 256 code units. With small deviations based on how something interacts with SharePoint. As I work with Japanese file names, and sometimes ...
0
votes
0answers
27 views

How to retrieve users from “list permissions users” of any LIST in SharePoint 2010 Client Object Model?

These code is giving me all users of the site, but need to get Users that are in List Permissions of any LIST (not Library) i.e of Project Task or Custom List. Thank you Web web = _ctx.Web; List ...
0
votes
1answer
430 views

Cannot invoke HTTP DAV request. There is a pending query during OpenBinaryDirect

I've to move some items from one document library to an other one in a different site. I use object client model to do this My issue is having an exception while i'm trying to open the file and here ...
2
votes
0answers
50 views

Possible to change view style client-side?

Is it possible to change the view style (for example to Shaded) client-side (using CSOM, JSOM or web services)?
1
vote
1answer
163 views

How to remove recent node from quick launch using CSOM?

Code looks pretty straightforward but fails with below exception "The collection was modified. Enumeration operation may not execute."} private static void ...
0
votes
0answers
31 views

Is it possible to use UserProfileService to return all current Birthdays?

I am new to the UserProfileService web service, the url based service accessed through /_vti_bin/userprofileservice.asmx In reference to writing a JavaScript CSOM web part, I am wondering if it's ...
8
votes
2answers
4k views

How to get List by Url using SharePoint 2013 CSOM

SharePoint 2013 CSOM API contains the following methods for accessing List object: ListCollection.GetById method - returns the list with the specified list identifier ListCollection.GetByTitle ...
1
vote
1answer
213 views

vb.net com: get list by url

Is it possible to get a list by url? Something like this. Dim list As SP.List = ctx.Web.Lists.GetByURL("site") If that isn't possible, is it possible to get the guId by using the page id?
3
votes
2answers
89 views

XsltListViewWebPart and custom link column

I have a XsltListViewWebPart with a custom link column used for change a value on current listitem using JavaScript. <a href="javascript:ApproveRejectRDA('{@ID}', true);" title="approve"> ...
0
votes
1answer
90 views

Trying to get lookup (Title) value, but returns null only in Client Object Model

I have this query: <View> <ViewFields> <FieldRef Name='Title' /> <FieldRef Name='itlgCategoria'/> ...
0
votes
1answer
432 views

How to create a group in a subweb using CSOM?

I need to create a site with broken permission inheritance. Then I need to create a Members group with contribute access and add people to it. The following code adds the group to the site ...
0
votes
2answers
271 views

Modify list view with JSOM

How can I make fields invisible on my list view, all items? It is something wrong with my code now: it changes the view but the only field it is displaying is Title and Modified. I want to display ...
2
votes
1answer
283 views

How create Sharepoint online site with custom template?

I need to create site in SharePoint Online from SharePoint hosted app. I used code like this: var webCreationInfo = new SP.WebCreationInformation(); webCreationInfo.set_webTemplate('STS#0'); ...