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

learn more… | top users | synonyms (1)

1
vote
1answer
812 views

Sharepoint 2013 App access cross site collections

I'm using SharePoint 2013 and I wrote an AppPart that needs items of a list other than it's host site collection. But it keeps popping up an error indicating that my request has been failed. Access ...
1
vote
1answer
241 views

Get Sharepoint 2010 search results using Javascript Client Object Model

I need Sharepoint search results from Cient Object model using javascript Client object model. Can anyone please tell me how to do it for sharepoint 2010
0
votes
1answer
56 views

Obtain 'Tags' of SharePoint item using the Client ObjectModel

I would like to obtain the 'Tags' for each SharePoint (2010, 2013) list item (either a document in a library or an item in a list) using the Client Object Model. I haven't found any API that let's me ...
0
votes
1answer
102 views

Display Form Text Inaccessible via JS

I'm overriding the Display Form of a list as per Mark Rackley's blog post: http://www.sharepointhillbilly.com/Lists/Posts/Post.aspx?ID=47 For this particular list, I need to parse a text field, split ...
0
votes
1answer
70 views

Use REST or XSL to get a Table with totals

I have a list with items that contains several columns like: Year Month HourCategory1 HourCategory2 HourCategory3 Now I want to create a table that shows only totals of the hour categories: ...
0
votes
0answers
42 views

In SharePoint 2013, adding selected webparts to a page

I have been given an interesting problem to solve. We have a publishing site in SharePoint 2013. Requirement: Every user should able to customize their home page with ease. Load available webpart ...
0
votes
1answer
237 views

Bind ListItemCollection as a DataSource of a DataGridView

I am using SharePoint Server 2013. I am trying to show a list data in a DataGridView in a windows forms application(client application). I obtained the ListItemCollection object related to the ...
1
vote
1answer
92 views

Updating the locale using the Client object model

I'd like to set the the Site Settings -->locale setting to English (United Kingdom) using the client object model. Is this possible? This setting can be found browsing the SP site Site Settings --> ...
1
vote
1answer
69 views

Adding a logo to site and sub-site using the Client Object Model

How do you add the url of a logo for the site and sub site using the client object model. This functionality can be found browsing the SP site. Site settings -->Title, Description, and Icon-->Logo URL ...
0
votes
1answer
527 views

Using REST API to get Site Groups in SP 2013

I'm trying to use the REST API in SharePoint 2013 to get the site groups. I've been using this link for a little help... http://msdn.microsoft.com/en-us/library/jj245927.aspx It's to do it with the ...
0
votes
1answer
760 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
0answers
109 views

Trying to get all selected items from a list

Im trying to get all items selected in a list but unable to do so with the code below: getItem = new TextBox(); getItem.Text = "get item"; getItem.Attributes.Add("onkeyup", ...
4
votes
2answers
307 views

Programatically setting Site Collections Administrators in SharePoint 2010 using Client Object Model

I am writing a program where I want to be able to add/remove user/groups as administrator for a given Site Collection. I am using Client Object Model API for SharePoint 2010. I havent been able to ...
1
vote
2answers
3k views

How to authenticate user in sharepoint online using javascript

I have one sharepoint online 365 site. In that one public site will be there. In that there is sign-in option. Generally When ever user clicks on signin it will redirect to microsoft login page. But i ...
0
votes
1answer
106 views

JavaScript OM to Approve Designer Workflow Task

I have a SharePoint Designer 2010 approval workflow and I am attempting to approve the tasks via JavaScript Client Object Model. I am able to change all of the fields to "Completed"/"Approved" but the ...
2
votes
0answers
105 views

Change content type order via Javascript/ECMAscript

In my SharePoint-hosted app, I use javascript to apply a content type called "Order" to a list in my app. When users click "new item" to upload a document, I want that document to derive from my new ...
1
vote
1answer
151 views

How can I get a list of all user alerts set on a site collection in SPO?

I need to retrieve a list of user alerts set on a particular site collection in SharePoint Online. This is possible through the web UI under Site Settings -> User Alerts, but requires that I choose ...
0
votes
1answer
1k views

Add an existing WebPart Using the Sharepoint client object Model [duplicate]

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 ...
0
votes
1answer
126 views

Sitemap with site owners using jquery/javascript

I am having scenario where i need to create site map webpart using jquery or javasscript i want to show all the subsites and their owners of each site with hieracrchy .can anyone help me in ...
0
votes
0answers
211 views

How to add and delete items in SP list using multi select box?

My question is that I am using a multi select list box to insert selected data to sharepoint list and I am using ecmascript object model. <select id="dd" multiple="multiple"></select> ...
1
vote
1answer
219 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, ...
1
vote
0answers
423 views

Javascript in CEWP queries a list every time dropdown is changed on NewForm.aspx not working

I am trying to apply javascript in a CEWP to a NewForm.aspx page of a simple custom list. Basically, the idea is to auto-populate a text field on the new item form whenever a dropdown column's ...
1
vote
2answers
2k views

SharePoint COM - SP.ClientContext(siteUrl) - Object doesn't support this action

Using the SharePoint COM to update a list item, but my function is failing. function updateProjectEC(projID, totalEC) { if(totalEC !== 0) { console.log("projID: " + projID); ...
1
vote
1answer
610 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 ...
1
vote
1answer
303 views

How to programmatically check if the current sharepoint user name and password?

Hi, i am using client object model in c# win form. How to programmatically check if the current SharePoint user name and password is correct? here I log in using SharePoint Site URL, username and ...
1
vote
1answer
254 views

Create C# web service that returns SharePoint ListCollection

I want to create a WebService that returns the SharePoint ListCollection in JSON format. I have tried by using following code: ClientContext ctx = new ClientContext("mySite"); ctx.Credentials = new ...
3
votes
1answer
297 views

Creating a SharePoint Wiki Page via JavaScript and REST or CSOM

I'm fairly new to developing SharePoint 2013 Apps, and I was tasked to customize the Create New Wiki Page for a Site. The user has to type in the Title, I do some processing, and then when everything ...
0
votes
0answers
19 views

SharePoint CSOM in Silverlight Returns NO DATA

Here is the Code: string SPUrl = "https://mysite/sites/ProjectSites/Project1/"; ClientOM.ClientContext SPContext = new ClientOM.ClientContext(SPUrl); ClientOM.Web mySPSite = SPContext.Web; ...
1
vote
1answer
87 views

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 ...
0
votes
1answer
41 views

RemoveUserFromSite failing (500 Internal Server Error)

I've created this function to delete a user from my site collection. function removeUserFromSite(){ userHTML = $('#my_SiteUsers option:selected').text(); //check if default user selected ...
0
votes
1answer
295 views

SharePoint Apps Getting the GUID of App-Provisioned List using JavaScript and CSOM

I'm a Sharepoint App beginner. I have a SharePoint 2013 App that provisions List. How can I get the GUID of those list using CSOM and JavaScript? Here's what I got so far: var lists; ...
0
votes
0answers
71 views

Trying to get list of groups a user belongs to

I came across this post showing how to create a permissions management webPart using SPServices. I tried to do it in SP2010 but keep getting error " User not found". I think it has something to do ...
0
votes
0answers
38 views

Using LINQ to get roll-up data

project1 completed 29/12/2013 project1 notcompleted 12/12/2013 project1 completed 07/12/2013 project1 completed 09/12/2013 project2 completed 19/12/2013 project2 notcompleted ...
1
vote
0answers
85 views

Default.aspx (Reference Error: AddItem is not defined)

So I'm trying to push through learning how to code in the SharePoint environment. I created a script in a text file that i'm calling through a content editor webpart. When I debug the page using ...
0
votes
1answer
117 views

Sharepoint 2010 Javascript Client OM, get user data (not current user) via javascript object model

There are plenty of examples of getting the current user via javascript object model in SharePoint 2010, but I am looking for help with getting any users email/title when I have the loginName. There ...
0
votes
1answer
570 views

Add user to sharepoint group

I want to add a user to SharePoint group (in another site collection) using JavaScript API. Here's my code var clientContext = new SP.ClientContext("https://MYURL/sites/dev2/"); var ...
0
votes
1answer
179 views

How to get the current shrepoint client context site?

i am using C# windows application. i want to access the SharePoint site to client Om. Normally we are using, ClientContext objContext = new ClientContext("//Sharepointsite"); but my question is ...
2
votes
3answers
1k views

How to use “SPContext.Current.Web.Url” in client object model?

When working with server side code we can use the following line to obtain the url of the current web site: var url = SPContext.Current.Web.Url; How can we do the same when working with the client ...
2
votes
1answer
144 views

Difference between GUID and UniqueId

What is the difference between GUID and UniqueId? They are both globally unique ids and from the client side we can see they are not the same: ctx = new SP.ClientContext(); web = ctx.get_web(); list ...
0
votes
1answer
260 views

How to utilize audience targeting with javascript?

Im creating a SharePoint-hosted app (restricted to use client side code only), and I want to retrieve documents from a library. Each document have a Target audience field. I want to, in javascript: ...
0
votes
0answers
160 views

Unable to connect to sharepoint site using Sharepoint Client Object Model

This is my first attempt in using the the Sharepoint Client Object model. I'm writing a console application to connect to one of our sharepoint application sites. I'm trying to run a basic example to ...
1
vote
1answer
125 views

How can one create a custom list in JSOM based on a custom list template (STP) in 2013?

I have a custom list template (STP) in my list template gallery. I can retrieve the list template using the client object model in javascript. But it's not clear how to create a new list from that ...
0
votes
1answer
250 views

Can Event Receiver be used in Sharepoint Client Object Model 2010?

I need to e.g detect in a console application any updates that affect items in a SP list. Thanks!
1
vote
1answer
727 views

Update list column using client object model code in SharePoint 2013 goes in onFailure without giving errors

I am using javascript to write the client object model code in SharePoint 2013. I want to update a column of the form library but I am not able to do it. The code goes in the onFailure method without ...
0
votes
1answer
64 views

Custom newfrom (upload a picture and fill in the picture url)

I have to customize an announcement list new and edit form. In the form is there is a Picture Colum. But I don’t want the user to go first to a picture library, upload the picture, copy the picture ...
0
votes
1answer
99 views

What are the big enhancements in the 2013 SharePoint REST/Client API? [closed]

The MSDN mentions there are some enhancements in the REST/Client API, but the things it lists seem to already be in the 2010 APIs. Can someone please elaborate on the new features that are NEW In ...
4
votes
1answer
94 views

TaxonomyClientService GetTermSets - Error The maximum string content length quota (65535) has been exceeded while reading XML data

I'm using the TaxonomyClientService to retrieve the TermSets using the GetTermSets call, the code works fine except one of the result is getting big and I'm receiving this error The maximum string ...
1
vote
1answer
2k views

The property or Field not initialized exception even I request explicitly

I'm using the following code to get the user permissions on a list item in javascript csom context = SP.ClientContext.get_current(); var field = ...
1
vote
0answers
128 views

using sharepoint OOTB DragDrop.js library in Custom webpart

I implemented drag and drop file upload functionality with using REST api in my webpart . But i found an OOTB sharepoint dragdrop.js library which has numerous methods to create drag drop control. ...
0
votes
2answers
81 views

Client Side Object model code goes in onFailure function

I am using the client side object model to approve multiple items from the form library. I need to access the values of some of the columns of the form library. The following is my code: var ...