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

learn more… | top users | synonyms (1)

0
votes
1answer
104 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 ...
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 ...
1
vote
2answers
544 views

Problem with Calendar CAML Query

i have a problem with a CAML Query for a Sharepoint Online(Office365) Calendar. I try to get all Calendar Appointments between two dates. Here is my code: private void getFreeDays() { ...
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
259 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: ...
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
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
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); ...
3
votes
3answers
1k views

Prevent/override standard Modal Dialog close button(X) from closing

I want to validate custom modal dialog form and if its not ok, prevent form from closing. For this purpose, I attached to X-close-dialog-button. Problem is to prevent it's default behavior. function ...
1
vote
1answer
488 views

SharePoint 2013 - How to add an action to a Callout

I want to add a custom action on the default Callout for Document Libraries. The only instructions I could find on this subject show how to override the entire FooterTemplate on an existing Callout ...
1
vote
1answer
253 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 ...
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
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; ...
0
votes
1answer
294 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
84 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
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 ...
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
177 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 ...
1
vote
1answer
390 views

Build CAML query by value from ClientPeoplePicker

I use these lines of code: <SharePoint:ClientPeoplePicker ID="clpUser" runat="server" UseLocalSuggestionCache="True"/> JS: var peoplePicker = ...
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
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
177 views

Sharepoint 2013 publishing page creation using Client Object Model

I am using SharePoint 2013. Is there any way I can programmatically create a page using ONLY th Client Object Model? Also notice that the page should be editable for further use.
4
votes
5answers
13k views

HTTP 401, Unauthorized using the Managed Client Object Model

I have a Windows 7 system built (per MS' instructions) with SharePoint 2010 Server. I'm writing a simple console application on it that attempts to use SharePoint's Managed Client Object Model to ...
2
votes
1answer
159 views

Sharepoint 2010 javascript client object model - downloading items and item attachments?

Is there a way, so that you can download the items from a list and all its item attachment files in one context call? Currently I am downloading all the items, then looping through each item, and ...
0
votes
1answer
249 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
0answers
112 views

SharePoint Online External Sharing Feature - Available through API?

I have a case where we would like to create a web part for use in SharePoint Online where users can request to share a site with an external vendor. We would like to automate the process of Sharing to ...
1
vote
1answer
757 views

Submit selected items of ListView in Request (used in Webpart)

I develop a WebPart using VS2010 for a SharePoint page. My problem: I have to submit the selected items of the ListView to the WebPart code behind. The best solution would be to do it via the Request ...
0
votes
2answers
94 views

Can't read Start or End Times with Client Object Model from Calendar in SP 2013

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 ...
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
2answers
175 views

Advice on starting development for SharePoint in C#

I'm about to start development of client-side application (C# using .NET 4.0) that connects to SharePoint. Mainly to download/upload documents. I've found out that there are several options: using ...
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 ...
3
votes
3answers
7k views

Getting the URLs of the SharePoint sites, lists and list views using Managed Client Object Model

Let's say that I have created: A SharePoint site collection at http://mysharepoint/. A subsite of that site collection titled Team site at http://mysharepoint/teamsite/. A list titled My List ...
1
vote
1answer
191 views

How do I set a SharePoint Document Library path to the Setting page in a C# Windows Application?

I have a Windows Application for scanning the document and store that document to a SharePoint document library. When I'm finished scanning, I want to select the SharePoint document library path in ...
0
votes
0answers
53 views

field 'choices' not initialized not requested

Hi im using the following code to get choices of a Choice site column. some times Im getting 'Chices' not initialized error in console. var searchtaxonomy_context = SP.ClientContext.get_current(); ...
1
vote
1answer
188 views

Javascript Object Model; possible to return whether item has permissions under inheritence or not?

So if I am using the COM/JSOM, and normal GetListItem, can is there something I can add to the Include method, that will allow me to see if the item returned has permissions under default inheritance ...
1
vote
1answer
544 views

SP2010 JSOM: updating with CAML where clause

So I learned and have used the following to update a list item by ID using Javascript Client Object Model: function updateItem(passedID) { var ctx = new SP.ClientContext.get_current(); var myList = ...
0
votes
0answers
79 views

Filter SharePoint documents based on a Tag filter using the Client Object Model

I am successfully fetching SharePoint documents using a CAML query via the Client Object Model. I would now like to add list of tags as a filter to this query, so that only documents tagged with ...
0
votes
0answers
161 views

Programatically getting SharePoint 2013 document uploader destination folder structure

I want to add documents to my document library folders programatically. I don't know how to get the destination folder structure to upload documents to SharePoint. How do I get destination folder ...
2
votes
4answers
10k views

Get Items Under Folder CAML

I am trying to retrive all items that are under a certin folder, in a document library. this is what i have so far List DocumentsList = clientContext.Web.Lists.GetByTitle(list); CamlQuery camlQuery ...
9
votes
1answer
173 views

Passing args to QuickLinksDialog with JS

I have a small button on a site which when i press should start a QuickLinksDialog and fill in some of the fields there. Everything goes good and well except the fields (like: title and url) still ...
1
vote
0answers
69 views

Add an app from the corporate catalog using client object model

I want to install an app that is in my corporate catalog using the client object model. I've found that I can install an app when I have the app locally. I'm then able to load it in as a stream and ...
0
votes
1answer
59 views

Client Object Model, wait for a list to load

I'm writing some javascript that modifies a SharePoint list, I've added it to the page using JSLink. Sometimes the script fails because the list appears not to have fully loaded. If I add an alert ...
0
votes
0answers
129 views

SharePoint 2013 custom TimerJob gets no results from list but same code as a console program returns results

Can anyone provide any ideas on why the below query returns nothing when inside a custom timer job. But when run from a console program it returns results. Note, both console program and OWSTimer.exe ...