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

learn more… | top users | synonyms (1)

0
votes
2answers
619 views

How to get display name from created by field in sharepoint client object model?

In my SharePoint JavaScript code, I am retrieving items from a list in my SP 2010 environment. I used a camel query to download specific fields. One of the fields was created by (person who created ...
0
votes
1answer
344 views

Client Context executeQuery() works in console app but returns null object when executed from CRM Server

I have the function GetDocumentLibrary which must return a libray from sharepoint site. When I execute it from a Visual Studio Console Application it works and return the library with all ...
0
votes
1answer
520 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 ...
8
votes
4answers
19k views

Get Site Collection full URL using javascript

I want to get the URL for my site collection. One way I thought I could do it was using the window.location in javascript and getting it that way. I know that you can use ECMA script and the client ...
0
votes
1answer
510 views

How to create a new document from a Document Template using Client Object Model

I require to programatically create a new document using the Document Template URL of the document Library and this requires to be done using the Client Object Model. I also require to do this without ...
0
votes
1answer
36 views

JSOM context newly created id reference when creating more than one item

I am using the COM JavaScript/jQuery to get, create & update some list items. I have two lists and every time I create a new item in one list, the newly created id is something that I want to grab ...
3
votes
2answers
283 views

Bug? 2010 Document Sets via Client Model shown as folder

I got a frustrating problem: When I create a document set via Client Object Model, the document set is created as intended as far as it concerns the appearance outside the treeview. It's shown as ...
0
votes
2answers
548 views

Import bulk data (over 5000 List Items) into SharePoint

I have an Microsoft Office 2010 AddIn which imports Data into SharePoint. The tool creates a Dictionary with over 5000 Values. Every Value is a C#-Class with Data and represents a SharePoint List ...
0
votes
1answer
30 views

Client Object Model: How to get the credentials for windows authentication?

In my .Net application I am using Windows Authentication. I need to save a document to SharePoint, and to do this I need to use the Client Object Model with the Microsoft.Sharepoint.Client namespace. ...
2
votes
1answer
749 views

How to open file in adobe reader using command line without checkout from Javascript?

I am working on print functionality. I am printing the PDF files (uploaded in SharePoint Library) using Adobe Reader command line from javascript. I am using ActiveX object to call the cmd. refer ...
1
vote
1answer
383 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.
0
votes
1answer
345 views

Dynamically create metadata and associate it with File using Client Object Model

Is there any way to dynamically add metadata in the upload file. I am using the following code in this regard. File uploadFile = context.Web.GetFileByServerRelativeUrl(location); //check out to make ...
1
vote
1answer
21 views

Use GroupBy on ListItemCollection using CSOM

I am trying to do a GroupBy on a bunch of items that I have retrieved using CSOM and when I try do a foreach loop to go through them I get method not supported exception. List contactsList = ...
5
votes
2answers
4k views

SharePoint 2010 ClientObjectModel : Find Item by GUID

I have a list of 6000 listitem GUIDs. I need to check if each item still exist on the Web. Previously, I was using the SPWeb.GetFile(GUID) method to check the item. But now I need to convert that ...
3
votes
0answers
38 views

Get Library and Folder from document guid (C#)

Information given I am using version 16.0.0.0 of the Microsoft.SharePoint.Client library. There are several different document libraries in the SharePoint site. In code, we are given a list of ...
0
votes
2answers
682 views

How to get the current SharePoint 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
1answer
1k views

System.ServiceModel.ServiceActivationException “A relative URI cannot be created because the 'uriString' parameter represents an absolute”

The client object model code in my application is throwing the following exception. How to solve it?. System.ServiceModel.ServiceActivationException: The service '/_vti_bin/client.svc' cannot be ...
0
votes
1answer
959 views

SPServices - GetRolesAndPermissionsForCurrentUser

I have a list where one group of users is not allowed to delete items but they have view and edit permissions. All items in the list contain an attachment. However, users are not allowed to delete the ...
0
votes
3answers
168 views

get current user info using jquery ,REST and com

My goal is to get the login name and picture for the current user. I am using SharePoint 2013 Foundation. I tried three method and non of then worked correctly: This is with jQuery SPServices: ...
1
vote
2answers
234 views

How to set field type choice using csom (c#)

I have a field type: Choice (menu to choose from) which is not multichoice. How do I set a value? I have found code for multiple choice but it doesn't seem to work for single choice.
0
votes
1answer
397 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 { ...
0
votes
2answers
2k views

Remove non full controlled Permission Sharepoint Groups from a SharePoint List using Client Object Model

I have SharePoint List which has stopped inheriting from the Parent Sub Site. I need to retrieve the SharePoint Groups which are not been assigned with Full Control on the List. Then I need to remove ...
0
votes
1answer
28 views

ReferenceError: itemID is not defined (JavaScript)

I'm trying to grab data from an external list using ecmascript. I'm running into a slight problem. I'm not getting an error popup, however, in debugger mode it's referencing the above error message ...
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
2answers
364 views

Windows 8 App using COM dlls of Sharepoint gives error “Cannot resolve Assembly or Windows Metadata file 'System.Web.Services.dll'”?

I have created a sample app using Windows 8 C# XAML to get site info of SharePoint 2010 using COM Dlls. I have added reference of: C:\Program Files\Common Files\microsoft shared\SharePoint ...
1
vote
1answer
423 views

How to get server datetime without postback using JSOM or services

My application page may be long time without reloading, and user changed system date and time. And I need to know datetime from server, not from client.
9
votes
8answers
11k views

How do I determine a user's SharePoint group membership using the client object model?

I want to redirect users from a landing page to another page in SharePoint 2010, based on their group membership. I need to do this using JavaScript (ECMAScript) and not server side code.
0
votes
1answer
22 views

How to determine authenticated status on client side?

Do you know any syncronous way to get IsAuthenticated status for currentRequest in client side via javascript? I can get current user via client model, but it will be asynchronous. ...
1
vote
2answers
51 views

Refresh sharepoint parent modal dialog on closing child popup

I have a button in a modal popup, on clicking that button another modal popup opens on top of that. Now I want to refresh the containing page of parent modal dialog on closing child popup. my code ...
0
votes
1answer
26 views

Client object model: orderby in camlquery doesn't work

I have a list on SharePoint 2010: (only showing the first item) How can i get that list alphabeticly? I use a camlquery to try this but it doesn't work. I do get the list but it is in a random ...
0
votes
1answer
444 views

502 DNS lookup failed error when using SharePoint 2013 CSOM

I am facing an issue while using CSOM in SharePoint 2013. I have configured an alternate access mapping for our site to run on http://mycustomdoamin.net/ The site is running fine and I am able to see ...
1
vote
1answer
49 views

Proper way to call multiple functions using SP.SOD.executeFunc

I need to make sure sp.js is loaded before I call several functions. I currently call them as follows in SP 2013. It works, but I suspect there is a better/more efficient way. ...
2
votes
3answers
201 views

SPWeb.AlternateCSSUrl equivalent Client Side Object Model

Does someone know the equivalent of SPWeb.AlternateCssUrl in the client side object model? Thanks
2
votes
2answers
808 views

Getting user email from a List Item column using Javascript

I am creating a Hosted app using NAPA on Sharepoint 2013 (Office365). I need to retrive a user from a list column and get the user's email. SP.List.getItems with a query returns a listEnumerator ...
1
vote
1answer
1k views

set multiselect lookup column using jquery

I have a Multi select Look up column which as you all know is a control with two list boxes and "Add or Remove" Buttons. The user populates the right-hand side of the control with some values by ...
0
votes
2answers
87 views

Loading image freezing with Javascript Object Model and jQuery Promises

I have some code using the javascript object model to get items for several dropdown boxes on a form. I also heard that using Promises was the way to go for speeding up things and created 2 wrapper ...
0
votes
2answers
40 views

How to get all subsites using ClientContext Object in SP 2010

I need to find all the subsites of particular sites and fill the drop down using ClientContext Object
0
votes
1answer
23 views

How to fill drop down dynamically using ClientContext object in sharepoint 2010

I need to fill the dropdown from the sharepoint list using ClientContext object.
0
votes
1answer
35 views

An error “The remote server returned an error: (403) Forbidden.” [duplicate]

Below is the code and I am getting error in context.ExecuteQuery(); using (ClientContext clientContext = new ClientContext(url)) { NetworkCredential credentials = new ...
0
votes
2answers
2k views

Jquery is not working on sharepoint date time control

Hi In my application page i have a sharepoint datetime control. I am using jquery on text changed event to calculate the number of days and displaying in a text box. Now i want to fire the same event ...
0
votes
1answer
47 views

JSLink Client-side rendering

I need to render some fields client-side, I followed this guide: Client-side rendering but this code is not working: (function () { // Create object that have the context information about the ...
2
votes
4answers
4k views

Unable to get property 'get_current' of undefined or null reference

$(document).ready(function () { var count = 0; retrieveCurrentListProperties(); function retrieveCurrentListProperties() { clientContext = new ...
0
votes
0answers
28 views

Run MVC App with Sharepoint as backend for Document Storage

My company has a small sharepoint site that we're hosting. We are almost exclusively using it for document storage, and we don't have very many documents. At the same time, we are developing an MVC ...
7
votes
2answers
6k views

Check if user is in a specified group

I would like to check with JavaScript if the current logged user is in a specified and specific group (for example called "Admins Group"). How can I do? Thanks
2
votes
3answers
4k views

Why is list.GetItems pulling more fields than specified in my CamlQuery?

I am trying to pull back just specific columns in a list using the .NET client object model. (i.e. using Microsoft.SharePoint.Client;) This is the CamlQuery specifying just fields in the DefaultView ...
0
votes
0answers
26 views

Upload/ download multiple documents to library It need to upload in each folder for an ID…

I need to upload multiple document form .net Aspx page to SharePoint document library. In .net having a multiple record, For Each record having the Multiple file upload option having different ...
5
votes
3answers
5k views

How to Use ECMA CSOM to Set a Field of Type SPFieldUserValue

I have a JavaScript array containing the string representation of some usernames (domain\username format). Using the JavaScript CSOM, what is the best way to create a new item and add those usernames ...
0
votes
0answers
46 views

Document Set created using SPServices shown as folder in WelcomePageView

After creating Document Set programatically using jQuery SPServices, if i click on Document Set Name it showing AllItems.aspx page instead of default docsethomepage. I checked in the Welcomepage view ...
0
votes
2answers
339 views

SP2013 online : set_formDigestHandlingEnabled Error

I get the error : Object doesn't support property or method 'set_formDigestHandlingEnabled' when I try to get the current SPContext object from javascript code in an Office 365 site. I am ...
0
votes
0answers
21 views

Remote access development

I'm relatively new and have tried to search posts regarding this problem but I'm not sure whether I'm hitting the right sites. The scenario is this. I have a sharepoint 2013 installed on ...