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

learn more… | top users | synonyms (1)

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
25 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
1answer
16 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
3k 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
16 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 ...
5
votes
2answers
5k 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
3k 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
17 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 ...
2
votes
2answers
183 views

SPWeb.AlternateCSSUrl equivalent Client Side Object Model

Does someone know the equivalent of SPWeb.AlternateCssUrl in the client side object model? Thanks
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
23 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
1answer
487 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
474 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
2answers
264 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 ...
2
votes
1answer
703 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 ...
0
votes
0answers
15 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 ...
1
vote
1answer
157 views

Enterprise Keyword not updating in SharePoint 2010 using client object model

Tried the following, it didn't give any error, but that column wouldn't update, while the Title did. please help me to resolve this problem using (Microsoft.SharePoint.Client.ClientContext ...
0
votes
2answers
640 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 ...
0
votes
1answer
30 views

why all documents are imported in check out

I've an issue with an import of documents in client object model. My import run correctly an imported my documents not check out and after 12h, every documents arrive check out. I changed nothing in ...
2
votes
1answer
677 views

Managed Client Object Model NavigationNode Url Property Incomplete

It seems the Client Object Model is stripping out the "query" part of a URL stored inside the NavigationNode elements. I am wondering if this is a bug or perhaps I am doing something wrong? Consider ...
1
vote
1answer
351 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
45 views

Getting fully qualified FieldUserValue instead of actual user name from SharePoint

I'm working on my first C# program, and it's a pretty simple program that uses a view of a SharePoint page to go through and delete things that are older than 5 days on that page. Before deleting the ...
0
votes
1answer
521 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 ...
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
305 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 ...
0
votes
1answer
879 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 ...
3
votes
2answers
18k views

Get current user in Client Object Model with javascript?

var ctx = new SP.ClientContext.get_current(); var web = ctx.get_web(); ctx.load(web); var user = web.get_currentUser(); alert(user); I used above code to get the current user using JavaScript, but I ...
0
votes
1answer
357 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
1answer
27 views

CAML Query works in U2U CAML Query Builder, but not SharePoint

I built a CAML query using U2U CAML Query Builder and it works when I execute it in the builder, but when I go to JSOM in SharePoint, I get the entire list and none of the filters from the query work. ...
1
vote
2answers
324 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 ...
0
votes
0answers
27 views

How to fetch 'nth ' items from a SharePoint List one by one through Client Object Model in SharePoint Online

I want to fetch nth Item from a SharePoint List from a SharePoint Online (Office 365) site and then compare it with the other Items of the SharePoint List. I am doing the following code. Can anyone ...
1
vote
2answers
51 views

Reference problem when trying to replace a master page file while keeping the original in CSOM

I have some logic that does some custom file provisioning in CSOM. It basically tries to upload various files located on a provided-hosted (Azure) site to mapped locations in the Sharepoint host site ...
1
vote
1answer
59 views

An unhandled exception of type 'System.Net.WebException' occurred in Microsoft.SharePoint.Client.dll

I try to access SharePoint list from a console app in .NET. My environment doesn't have SharePoint installed one and I write code in VS 2013. I want to access SharePoint 2013 list data. When I run my ...
1
vote
1answer
403 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.
6
votes
1answer
2k views

Context Menus - Send To not working in IE9

I have a document center with a custom master page. The page is designed with IE9/HTML5/CSS3 in mind. In my other question, I worked out how to fix the IM Presence icons by fixing some core ...
1
vote
1answer
129 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 ...
2
votes
1answer
144 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
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 ...
1
vote
2answers
790 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 ...
0
votes
1answer
431 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
2answers
25 views

Attach file in CustomList Item using Sharepoint.Client object

Hi is there a way to attach file in specific Custom list item? Currently i tried to add files on the root folder using below code: using (ClientContext context = new ...
1
vote
1answer
13 views

SharePoint integration outside farm

Can someone provide me an overview of the possible ways of interaction with SharePoint from an external source. For example add items to a list from an application not running in the farm. In a farm ...
1
vote
1answer
26 views

Guess SharePoint version based on connection parameters

My client application uses the SharePoint Client Object Model against SharePoint 2010 and 2013. I would now like to add support for SharePoint Online. Users of my application specify the 'Url' to ...
0
votes
1answer
4k views

How to use SharePoint 2013 search keyword query refiners and refinementfilters?

I m working on requirement where I need to write a client side managed code in C# to pull search results based on the free text query and then should be able to refine the result based on the Keyword ...
1
vote
2answers
72 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 ...
0
votes
2answers
33 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
22 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
83 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' ...
3
votes
2answers
387 views

Check if logged in user is member of AD group with ECMA script SharePoint 2013

There is active directory group added to SharePoint group. How would we can check that the logged in user is member of that active directory group using ECMA script?
0
votes
2answers
485 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 () ...