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

learn more… | top users | synonyms

0
votes
3answers
4k views

Get Sharepoint data synchronously with JavaScript

I was wondering is there some way to get list items form SharePoint with JS synchronously. All methods I've found required to specify a callback method. As I am building a custom JS validation for ...
1
vote
2answers
1k views

Is it possible to change the visual style of a JSGrid row?

I am working on a SharePoint solution using the SharePoint JS Grid control to display data. What I'd like to do is to change the default style (mainly background color) of specific rows in the grid to ...
0
votes
2answers
1k views

How to Client Side connect to Sharepoint 2010 with claim based auth

I had to create an application which connects to Sharepoint. The interested Sharepoint Application is set to work ONLY with claim based Authentication, so I cannot use the classic: NetworkCredential ...
2
votes
1answer
2k views

Javascript call to NewItem2 error “TypeError: Cannot read property 'tagName' of undefined”

Overview I have a CustomAction for a button on the ribbon that calls a command in a javascript file. The command fails in the inplview.debug.js file on the following lines (1745 - 1748) in the ...
2
votes
2answers
751 views

Does Managed Client object model work for Cross Domain?

I want to know whether managed client object model works in cross domain cases. For example I have a console application in Domain A, can I use managed client object model in the console application ...
0
votes
1answer
191 views

Change order of user profile property

Hi i want to change the order of user profile property in a subtype i found out this link SharePoint 2010 - Change order of User Profile properties which is changing only in default sub type but its ...
1
vote
2answers
1k views

Add value to Choice field through ClientContext API

I'd like to add and select values to a choice field in a document library. Something obviously more tricky than I remembered. I'm doing something like this but it doesn't work. The value gets added ...
2
votes
2answers
3k views

HTML from Rich Text Field as Plain Text

First off I want to be clear I am using the Silverlight Client Side Object Model in solution. So I cannot use objects/properties from the server object model. What I am trying to do is get the plain ...
0
votes
2answers
4k views

How to correctly get a JavaScript SP.Web object's ID and URL before loading

I was working on a project where I needed to get the current web's ID or URL (sometype of unique identifier) in javascript without making an service call (executeQueryAsync). I didn't seem to be able ...
3
votes
3answers
8k views

How to get Item from ListItem with Client Object model

I'm trying to printOut some items from a ListItem. But when run the code I get following exception: "Invalid usage of query execution. The query should be executed by using ExecuteQuery method on ...
3
votes
1answer
607 views

AddLookup using the client object model?

Trying (desperately) to find the Microsoft.Sharepoint.Client equivalent of SPList.Fields.Addlookup My code: ClientContext ctx = new ClientContext("http://sharepoint/"); Web website = ctx.Web; ...
0
votes
3answers
4k views

Upload limit and Exception when uploading files via Client Object Model

We have an windows application that uploads files to SharePoint 2010 via client object model. We have raised the upload limit as in the following article: ...
2
votes
4answers
2k views

where clause is ignored when query list

I have a CAML query which returns lists by a lookup field. here is the query <Query> <Where> <Eq> <FieldRef ...
0
votes
2answers
3k views

Uploading a Word Document to Sharepoint using SaveBinaryDirect() resulting in corrupted document

I am uploading a document to sharepoint site using client object model. using (FileStream fs = new FileStream(@"C:\temp\UlDoc.docx", FileMode.Open)) { File.SaveBinaryDirect(_cc, ...
0
votes
1answer
149 views

Disable windows auth, but access a resource in the site collection

I have a sitecol with anonymous access. I have a console code that uses client-object-model to query from a particular list in that site collection. This was working fine. But recently I had to ...
1
vote
2answers
1k views

Selecting single user from User Information List

I've got a problem with not being able to select a single list item from the User Information List, I have used U2U CAMLbuilder to build a query that extracts an entry with the ID = 1 When run in the ...
1
vote
2answers
428 views

Getting ECMAScript Client OM Intellisense to work in ASCX/JS

I can't for the life of me get intellisense working for the Client OM. It seems to work on another box I have tried so I'm wondering if I have found some kind of bug/configuration issue. I have tried ...
2
votes
1answer
393 views

Client Side vs Server Side Querying: When to use each?

Relatively new to developing for Sharepoint, but building a website with a lot of functionality. The frontpage alone is making 5 queries to separate lists and has numerous javascript libraries ...
1
vote
1answer
352 views

Working with client OM

I need to set currentUser to some item field in Client Object Model. How can I do it? I always use new SPFieldUserValue (//,//,//) in server code, but here..
2
votes
1answer
2k views

Incorrect Modified Dates on SharePoint Online for clients in other timezones

I've run into a strange problem with SharePoint Online. When updating or creating entries in a list using the Client Object Model, the modified date on the affected list item seems to be stored with ...
1
vote
0answers
547 views

Get Permissions with client object model

i want to add a permission on a folder who's inside a document library with javascript/jquery/client object model. The problem i have is, its a custom permission level created when some feature is ...
6
votes
1answer
2k views

JavaScript Client object model, rename folder

I am trying to rename a folder inside a Document library. Right now I get my item and everything is good but when I try to rename it using set_item('title', 'NewFolderName') it crashes and unwinds the ...
2
votes
1answer
626 views

set or update multiple values cascading lookup field using client object model

I'm struggling since a couple of weeks with setting a multiple values cascading lookup field using a client object model, I could set the first value but then It show me an error of invalid lookup ...
1
vote
2answers
2k views

CSOM Query on Hidden User Information List returning nothing

I'm trying to retrieve a user's profile picture from the hidden User Information List within Silverlight. I can't use the UserProfileService.asmx because I don't have the login name nor the GUID of ...
0
votes
1answer
2k views

SPDiagnosticsService.WriteTrace throws error “Object reference not set to an instance of an object”

I am trying to write entries into logging and have trouble doing so. Using Client object model on SharePoint foundation. Code is running from a console app. SPDiagnosticsService.Local.WriteTrace(0, ...
1
vote
1answer
2k views

HTTP 500, HTTP 401 errors when executing ExecuteQuery() on Client Object Model

I am using Client Object Model to access a document library on a VM SharePoint server where I do have 'FullControl' access to a Site & Site collection. The below code works on my SharePoint ...
0
votes
1answer
284 views

Missing eMail in SPUser

I have a small application that is making use of the SP-COM. I use the following code to get the current users email address: ctx = SP.ClientContext.get_current(); web = ctx.get_site().get_rootWeb(); ...
0
votes
1answer
210 views

Enumerate Summary links column values in JS COM

I defined a list where a Summary list is a coloum, in my javascript code i want to read the values of the links one by one... sliderText = listItem.get_item('Description0'); sliderTitle = ...
4
votes
2answers
5k views

Adding description to sharepoint link URL using the C# CSOM

I'm currently adding the URL except the description is an ugly link. I would like to add the description to the URL in a links list on sharepoint online. My current code to add a new item from an ...
0
votes
1answer
2k views

Getting list length from caml query

I am currently trying to determine the length of a list that is located on my SharePoint site. I am using a Caml query to retrieve the items in my list, but I can not figure out how to get the length ...
2
votes
1answer
406 views

Performance bottleneck on SharePoint upload method

Trying to eliminate a performance bottleneck on a method doing file and metadata uploads. According to the profiler on a line-by-line of the decompiled code, the majority of time is spent on ...
2
votes
2answers
779 views

Sharepoint 2010 Client OM - How to get the Last approved document version?

I am trying to use sharepoint foundation 2010 as file store for a website. Every document update must go thru an approval cycle and finally gets to a approved status to show up on the website for end ...
0
votes
1answer
461 views

Sharepoint linq throws error

I know this is a common problem and there are lots of suggestions on the internet, but non of them helped me to sort this issue out. I have created my data context class by using SPMetal.exe tool. I ...
6
votes
2answers
4k views

moveTo and moving documents from one library to another

I have followed and successfully implemented the excellent article: SharePoint 2010 ECMAscript – Copy\Move files to another document library – Part 2 located at: ...
1
vote
1answer
627 views

How strictly is Client Object Model functionality Security Trimmed & Person (User) object resolution?

I have a Silverlight Webpart Application running on a Sharepoint2010 Page. The purpose of this webpart is to take a spread of different sections of data and condense it into a more easily usable form. ...
1
vote
3answers
397 views

How to access documents with in a custom content type of Document Set

I have a Library, which stores document sets (the content type here is a documentset which contains more than one word document). Currently I can to get the items from the library using the below code ...
3
votes
4answers
2k views

Get SharePoint Server datetime

I was working on a functionality where we had to fetch list items from server using ECMA script (SharePoint 2010 Client Object Model) based on current datetime. The problem is that the datetime we ...
0
votes
1answer
690 views

Caml query returning multiple lists

Trying to load a list from library containing two files. The following code when tested in CamlBuilder it is returning single row according to the filename selected. But in the program it is returning ...
4
votes
2answers
5k views

Upload a document to a SharePoint list from CSOM with no limitations

I need to upload a document to a SharePoint list or folder using the Client Side Object Model from .NET (C#). What is the best way to do this? The requirements are as follows: Set metadata values ...
0
votes
1answer
546 views

Logical AND ,OR CAML Query not working in External List

I am using ClientContext Class and CAML query to retrieve items from External List in sharepoint 2010.I have built the query with Logical AND Condition in CAML Query like this string sDataFilter ...
2
votes
2answers
207 views

Client-side Object Model Load Test Metrics

I would like to know if anyone has done any load testing on using managed .NET Client Side Object Model (CSOM)? I am mainly looking for metrics (graphs, spreadsheets, etc.) on the following: Large ...
2
votes
2answers
2k views

SharePoint Client Object Model Assembly Distribution

I would like to know if it is illegal (against MS licensing agreement) to: Copy the Microsoft.SharePoint.Client and Microsoft.SharePoint.Client.Runtime assemblies from a SPF 2010 server to TFS ...
1
vote
1answer
358 views

Sharepoint managed client object model - Updating Eventdate in calender

I am using managed client object model in sharepoint and I am adding EventDate and on adding that I am catching exception which says Microsoft.SharePoint.SPFieldValueException if ...
2
votes
1answer
2k views

Delete item from Client Object Model

I'm trying to delete an Item from a list using the following code: using System; using Microsoft.SharePoint.Client; using SP = Microsoft.SharePoint.Client; namespace ...
1
vote
1answer
1k views

Create new Document in Document library with additional Text Fields in Silverlight (Client Object Model)

I have created a Silverlight Application that runs in a SharePoint 2010 web part. One requirement I have is to give the user a prompt to upload a file, and then send it into a specific Document ...
2
votes
1answer
816 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
2answers
2k views

Is <QueryOptions> valid in SP.CamlQuery for meeting work space

I'm trying to query all items in a meeting workspace list. I'm trying a query I think should work, but still only returns items specific to the instanceID. Is there a different flavor for client side ...
1
vote
2answers
6k views

What arguments can I pass to NewForm.aspx using SP.UI.ModalDialog.showModalDialog(options)?

I'd like to create a task with a pre-filled title, as well as set some other properties. I found this documentation that says I can pass arguments when i call ...
3
votes
3answers
10k views

Get User via JavaScript Client Object Model

Is there a way to get user information via the JavaScript Client OM? Something similar to the clientContext.Web.EnsureUser(userName) method. I am aware that there is the SPService JQuery library, but ...
0
votes
1answer
5k views

Error Running ExecuteOrDelayUntilScriptLoaded

Using IE9 (9.0.8112.16421) I receive the following error in the debugger while running the script I'm working on: "Unable to get value of the property 'toLowerCase': object is null or undefined" ...