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

learn more… | top users | synonyms (1)

1
vote
1answer
2k views

Retrieve Iist Item column values with column names on Item click, JavaScript

I need to retrieve List item column values with column names on item click. In SP2010, I have a XSL which calls the JavaScript. I have sent the list item id through the XSL into the JavaScript ...
0
votes
0answers
34 views

set properties for ShimFileCreationInformation object

I am writing some unit test cases using fakes framework. I am using an object ShimFileCreationInformation from Microsoft.SharePoint.Client.Fakes namespace. Now, I pass this object to a function. ...
2
votes
2answers
607 views

How do I get a collection of document libraries using Javascript CSOM?

I'm working on an UI feature for my SP2010 site and would like to display a number indicating how many documents were added to a specific library since the users last visit. The UI will display a box ...
0
votes
0answers
134 views

Filter/compare two arrays from CAML query

I'm using JavaScript/Client Object Model to retreive some data by CAML query. I've 2 CAML queries. One retrieve all data from a specified column. The other query retrieve data from same column ...
0
votes
1answer
68 views

Issue when getting library GUID through JavaScript

I'm using SharePoint 2010. I need to get some SharePoint data on a list item hyperlink click. Inside the JavaScript file there is a method getLibraryGuid() I get the targetLibrary value with no issues ...
3
votes
2answers
438 views

Sharepoint unit testing using fakes framework

I have an application which uploads a file to SharePoint via client object model. Now I need to write unit test cases for this application. The problem is, I how do I write test cases for the ...
2
votes
1answer
1k views

SharepointOnlineCredentials not working in an app

I want to authenticate against sharepoint online site using SharepointOnlineCredentials class. Below code works fine in a console application. But the same code is generating error when written in wcf ...
3
votes
2answers
1k views

View custom field property value using JavaScript

I'm using SharePoint 2010. Need to retrieve the Custom field property values using a JavaScript. [Trying to do this during item click in the SharePoint list item view. I call the JavaScript on the ...
1
vote
1answer
632 views

How to use JavaScript to get form data, and add it to a list

Obviously it is possible to gather data from a form using JavaScript. Microsoft also claims that is possible to add items to a custom list using JavaScript, although I have not gotten that to work. My ...
0
votes
1answer
252 views

Equivalent of GetRolesAndPermissionsForCurrentUser in SharePoint REST API?

I have this code which is used to check if a user has permissions to access the site or not. jQuery.support.cors = true; $().SPServices({ webURL: sites[index], ...
3
votes
3answers
8k views

Retrieve list item using CSOM on SharePoint online isn't working

I've been stuck on this problem for couple days, I develop app model on SharePoint online using provider hosted model. From clientwebpart, i want to access sharepoint list item. I can access list ...
0
votes
2answers
2k views

Grant Permissions to List Items using existing SharePoint Group using Client Object Model

I have found examples on how to add users to SharePoint Groups using Client Object Model. Can anyone help provide an example on how to grant permissions to items in a List using an existing ...
1
vote
1answer
220 views

Get list at site collection level using SP.js

I have this code which is meant to get data from a list at the site collection level. var clientContext = new SP.ClientContext.get_current(); var oList = ...
1
vote
3answers
2k views

Using CSOM to get list item count for multiple lists

I am trying to create a function which should loop through all lists on current web and display their current item count. My code so far: <!-- language: lang-js --> ZN.updateDocumentCount = ...
2
votes
3answers
258 views

Need a way to identify files which have no checked in version

I wrote a script that traverses a collection, it's document libraries and gets a list of all files. I'm trying to find all the documents which do not have a checked in version and require a user to go ...
0
votes
1answer
516 views

How to change 'Modified By' column value when a new file is uploaded in SharePoint 2013 using Client Object Model?

I want to change 'Modified By' column value of a file that is being uploaded using Client Object Model in SharePoint 2013. The problem is that the version of the file is changing. Kindly help me. The ...
0
votes
1answer
245 views

Synchronize excel file with SharePoint online list

I want to synchronize data from excel file with SharePoint list on office 365. I have already built a utility which uses client object model to achieve this but it is very slow as item count are in ...
1
vote
2answers
1k views

running SharePoint utility on non-SharePoint server

I wrote a utility in C# to copy files from a network directory to a SharePoint document library. When the sys admin tries to run the .exe from a non-SharePoint server, he gets the following error: ...
1
vote
1answer
101 views

Surfacing an SharePoint Online Access Services query for use externally

Is there any way to write a query in Access Services for SharePoint Online, and surface its results through either web services or the Client Object Model for .NET? Like the way that the tables are ...
0
votes
1answer
110 views

CSOM and master page and page layouts: .html vs .aspx vs .master

When applying master pages and page layouts using CSOM, should we generally operate using .html files? What would be pros and cons of using .html vs .aspx and .master files?
2
votes
0answers
118 views

How to access Page layouts and site templates using CSOM?

How to access Site Settings > Look and Feel > Page layouts and site templates using CSOM? The page allows end users to change these settings: Subsite Templates: subsites can use any site template ...
4
votes
2answers
2k views

How to enable publishing feature using CSOM?

How to enable site collection publishing infrastructure and site publishing features using CSOM?
1
vote
1answer
91 views

Get Workflow ModificationID via JavaScript Client OM

I create a dynamic link to the workflow Midification form in SharePoint 2010. I can get all of required parameters such as ItemID, ListId and Workflow InstanceId via Javascript OM. The only problem ...
5
votes
1answer
189 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
304 views

Jquery show loading progress [closed]

Good day, I have a page with several javascript pages that get loaded. How can I check that all the JS files have been loaded? I tried the below with just alert boxes. $(onPageLoad); function ...
0
votes
1answer
2k views

Add item in SharePoint 2010 document library using JavaScript [duplicate]

Is it possible to add a new item in a SharePoint 2010 document library using JavaScript (client object model)? I have successfully created list items in other type of lists, but when it comes to ...
0
votes
2answers
3k views

upload to document library subfolder in client object model

I'm using the Client Object Model to upload files from a network drive to a SharePoint document library. Here is how I would specify the upload location if I were uploading to the document library's ...
1
vote
1answer
105 views

I am not able checkin/checkout the files in sub folders in the document library using client object model. Below is the code I am using

public void CheckOut()// CHECK OUT FUNCTION { try { string siteurl = ""; string filePath = ""; ClientContext context = new ClientContext(siteurl); context.Credentials = ...
0
votes
1answer
394 views

Check-In & Checked Out files inside folder in Document library using Client Object Model

I am not able checkin/checkout the files in sub folders in the document library using client object model. Below is the code I am using. public void CheckOut()// CHECK OUT FUNCTION { try { ...
3
votes
1answer
725 views

Check- in & check-out files using client object model

As the title says, how can I Check- in & check-out files using client object model?
1
vote
1answer
684 views

Move documents from one folder to another in diferent library in different site collection from Client Object Model

I want find and move all documents from one folder to other in different site collection document library. Both the folders are at the sub folder level 3 from the actual list. Please let me know how ...
1
vote
1answer
425 views

How to create sub site context in sharepoint online using app model

I am trying to create a sub-site and some predefined lists in the existed site collection. I am successfully created the sub site in the site. But Now i want to create lists in that newly created ...
2
votes
2answers
411 views

Looping retrieved Items throws an InvalidCastException

I have some very simple code using the client object model to retrieve a list and all items from that list from a SharePoint 2013 Online site. When the ExecuteQuery() fires, I use Fiddler to view the ...
0
votes
0answers
37 views

Detect that an item has changed after it is tagged

I am using the Client Object Model to work with SharePoint items and also the 'SocialDataService.asmx' web service to work with tags. I use the 'Modified' field of a SharePoint item to detect ...
0
votes
2answers
524 views

Call executeQueryAsync method second time gives first time result

In the code I tried to get the data from 2 different lists. Input of the second query will be done after executing first list. $(document).ready(function () { $("#SearchButton").click(function () ...
3
votes
3answers
3k views

Sharepoint 2013 Client Object Model file larger than 2 Mb exception

I am new to Sharepoint and Client Object model. I am stuck with a problem and not been able to fix the issue. I want to upload files more than 10 MB using Client Object Model in Sharepoint 2013. I get ...
1
vote
1answer
317 views

Button to Show/Toggle Sharepoint Ribbon

I would like to add a button to a webpart we have already created that increases usability for our document libraries. I would like this button, when clicked to toggle the standard ribbon that is ...
1
vote
1answer
2k 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
657 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
91 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
236 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
104 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
1answer
365 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
178 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
148 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
2answers
1k 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 ...
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(); ...
4
votes
2answers
796 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
3answers
6k 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
221 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 ...