An acronym for Asynchronous JavaScript and XML

learn more… | top users | synonyms

10
votes
3answers
6k views

Can't upload a non-text file to SharePoint App via REST API

I am using the following REST code to add a file as an attachment to a SharePoint 2013 list item. <asp:Content ContentPlaceHolderId="PlaceHolderMain" runat="server"> <SharePoint:ScriptLink ...
8
votes
2answers
712 views

Use SharePoint 2013 “Working on it…” during ajax call

I'm trying to use the SharePoint 2013 "Working on it..." during ajax call. This is the code: function ShowWaitDialog() { SP.UI.ModalDialog.showWaitScreenWithNoClose(SP.Res.dialogLoading15); } ...
8
votes
3answers
288 views

Verify SharePoint user in ajax request

Consider the following: A logged-in user visits a publishing page in a SharePoint Online environment. The page loads data from a service running on another server using an ajax request. In this ...
7
votes
1answer
4k views

Fetch list of sites in site collection into jQuery

Is there a way to get the list of sites in the current site collection into jQuery as an array or other data structure? Thanks.
7
votes
3answers
3k views

How to asynchronously load and refresh a Visual Web Part?

We have developed a Visual Web Part for Sharepoint 2010 with Visual Studio 2010 (Visual Web Part project template). The web part loads some stuff and shows a list of items. It takes some seconds to ...
6
votes
4answers
6k views

SharePoint REST API call with more than 500 rows

I have an AJAX call querying the SharePoint REST API which will return more than 500 rows: $.ajax( { url: _spPageContextInfo.webAbsoluteUrl + ...
5
votes
2answers
10k views

JavaScript: How to reuse the “Working on it…” pop in

Sharepoint 2013: In have custom JavaScript code that makes Ajax calls. While loading I'd like to show Sharepoint's loading pop in: That is the one that greys out the underlying page and centers a ...
5
votes
1answer
634 views

SharePoint 2010 - Using REST to validate unique list item

I'm attempting to validate that a duplicate combination of staff (person/group field) + parent ID (lookup field) does not already exist in a list. Below you can see that I've added an ajax call to the ...
5
votes
2answers
3k views

Sharepoint 2010 Webpart Ajax not working

I have a custom webpart within Sharepoint and am trying to apply some ajax to the webpart. The same code works within a .net web application but not within a sharepoint web part. The code from the ...
5
votes
1answer
1k views

Ajax Calendar Extender Position is not working in SharePoint Webpart

I am using Ajax Calendar Extender, but it is not pop up next to textbox, it is appearing int the middle of the page. Here is the code: <asp:TextBox ID="dtEnginerring" runat="server" ...
4
votes
2answers
387 views

Is AJAX Built-in in SharePoint-Online ( SharePoint-Hosted Apps )?

As the title says, can I create a SharePoint-Hosted App and make Ajax calls right away? or do I have to import an ajax library or something like that?
4
votes
3answers
2k views

I'm trying to understang how AJAX and Sharepoint play together

I'm about to embark on a project whose goal is to take a Sharepoint wiki of documentation, and add an index as the left nav (right now, there's only search). As users click on an index item, the right ...
4
votes
1answer
146 views

AJAX/Rest only returning 100 items instead of full list

On an onchange event on a select box (filtered lookup column where the value is the item ID) i make an AJAX call to auto fill certain fields on a form. This works great except for it only returns 100 ...
3
votes
2answers
4k views

Creating Folder using REST and JavaScript

I'm trying to create a Folder in a SharePoint Image library. I found an answer here but I can't seem to get it to work var web = 'my relative path to the current web'; var lib = 'name of the image ...
3
votes
1answer
340 views

Delete List Item with Ajax

I've been trying a few options out, but I'm finding good SharePoint AJAX guides to either not exist or be hard to find. Very simple, I am rendering list items with a repeater, and I want to be able ...
3
votes
5answers
559 views

Proxy page for Office 365

I am working on an Office 365 (SharePoint Online) website, and I am looking for a way to retrieve data (xml, json) from remote sites that don't necessarily support JSON-P or CORS. I could use an XML ...
3
votes
1answer
8k views

Call WebMethod from JS in Visual web Part

I have ASP.NET web app that call some WebMethod from javascipt and fills textboxes. This is not all code, just example codesnippet function dataApp(text) { var loc = window.location.href; ...
3
votes
2answers
1k views

ScriptManager ServiceReference in SharePoint

I have always used jQuery.ajax to retrieve data from listdata.svc or lists.asmx in SharePoint and from some custom web services. Now I will try Microsoft Ajax Library and especially ServiceReference ...
3
votes
2answers
3k views

Help with getting the value of a look up field

Currently, I am using an ajax request to access the list items. The fields that are not lookups come as expected but the lookup fields come across as an ID of the object that corresponds to its ...
3
votes
2answers
2k views

UpdateListItems won't let you reset field value to empty?

I've recently discovered that the Lists.asmx ignores your attempts to reset a field's value to empty string or null with Lists.UpdateListItems. Not a very well documented limitation discovered by ...
3
votes
2answers
5k views

UpdatePanel with SharePoint 2010 web part

UPDATE protected override void CreateChildControls() { if (!this._error) { try { base.CreateChildControls(); ...
3
votes
1answer
609 views

sharepoint 2010 get value of choice field through api call

I have a sharepoint list ImageList, i have a column which stores its type The column name is ImageType the choices are "profile pic","thumbnail" etc i want to fetch these choice values for this ...
3
votes
1answer
797 views

Get distinct values via mechanism used when clicking “Show Filter Choices” on a Sharepoint list using Javascript

As many other people on this site seem to need, I'd like to get an array (or equivalent) of the distinct values in a field for a list. The canonical way of doing this is to retrieve the entire field ...
3
votes
2answers
146 views

AJAX Request not firing at Document.Ready

Had a question regarding an AJAX request I'm making via jQuery in my SP site page template. The code in question: //writes CSS classes to body script based on explicitly checked group membership ...
3
votes
1answer
294 views

Adding Controls to a Bing Map Webpart for SP 2010

I am using this WebPart to display Bing Maps, I did lots of research to find out, how can I put controls on it as one shown in picture in link but didn;t find any hint except AJAX might help, can ...
2
votes
2answers
9k views

Custom JSLINK rendering template - how do you get ajax paging working?

So I followed this post to implement paging in my custom JSLINK rendering template, and got that working great. The only downside to it is that the paging actions are full page post-backs whereas on ...
2
votes
3answers
2k views

Problem with SPGridView and SPGridViewRow.FindControl

In a SharePoint webpart I am displaying an SPGridView. The SPGridView control is inside an Ajax updatepanel and is bound to a datatable in the code. The columns for the gridview are created mostly as ...
2
votes
2answers
2k views

How to use jQuery and OData to expand multi user field in SharePoint 2013?

I am using jQuery to query a Sharepoint 2013 list and expanding the AssignedTo field (which is a Person or Group field type) in order to get the user id. I was able to get the code working when the ...
2
votes
3answers
3k views

SharePoint 2010 web service - GetListItems not working in Chrome & firefox

function GetListItems() { var soapEnv = "<?xml version='1.0' encoding='utf-8'?><soap:Envelope xmlns:soap='http://schemas.xmlsoap.org/soap/envelope/'>" + ...
2
votes
4answers
457 views

Why doesn't jQuery execute in a DataViewWebPart with asynchronous load enabled?

The jQuery scripts I have in a DVWP do not get executed when I enable Asychronous Load in the Ajax Options of the DVWP. They do execute when I disable Asychronous Load though. Any thoughts on this? A ...
2
votes
1answer
119 views

AssignedTo Column multi users via REST-API

Is it possible to set (Update/Create) 2 users to the AssignedTo column in SharePoint Online? I am using REST-API (JS). When I put one user with: AssignedTo "- 1; #USER@company.com" it works, ...
2
votes
2answers
52 views

How do I get my Web Part to automatically refresh

Sharepoint 2010 Enterprise - I have a web part which displays notifications from a list which have the ShowMe flag set to TRUE. Although I have Enable Asynchronous Automatic Refresh checked and the ...
2
votes
1answer
71 views

HTTPHandler Note Hitting the the breakpoint in VS2010

I'm trying to send some Async Data to the server form SP webpart. I added the HttpHandler to the Layout folder in webpartproject and registered it in web.config file for the SharePoint site. But the ...
2
votes
1answer
699 views

Javascript/Ajax errors on custom master page

I have a custom master page using a few JS utilities like jQuery and skel.js that has been experiencing some errors whenever the page loads. The errors are transparent to the user, but show up in dev ...
2
votes
1answer
455 views

Can't sync SIP Address, can't query it in search even when added manually

Issue 1 I'm trying to pull back a user's SIP address using the search service. I have this manually entered for the time being in a particular profile. My query: $.ajax({ url: ...
2
votes
2answers
6k views

SharePoint Cross Domain Request with jQuery

I've been going around in circles for a couple hours now to no avail. I had thought that what I wanted to do was not possible but some threads that I was reading on SO were saying otherwise so I ...
2
votes
3answers
3k views

Why web parts are loading sequentially?

In our home page we have multiple web parts that get the data from different webservices or from a recursive search in some lists in the site collection. We detected that all this calls were too ...
2
votes
2answers
237 views

SharePoint 2010: blocking the screen on load

We are hosting some SP2010 sites and some of our users are a little quick on the trigger and try to click on an order before the page is done loading, inadvertantly approving it by mistake. Repeated ...
2
votes
1answer
233 views

Update Panel not working in Sharepoint online sandbox solution

I have added a UpdatePanel on the webpart and then when I upload a .wsp to office 365 then & open the page(which contains this webpart) then error occur: Web Part Error: Sandboxed code execution ...
2
votes
1answer
702 views

CORS with SPServices + jQuery

I need to access from a different domaine on a mobile a sharepoint list. Here is my code, a simple get request : $.support.cors = true; $(function() { $().SPServices({ operation: "GetListItems", ...
2
votes
1answer
329 views

Safari web browser will NOT perform Asynchronous Automatic Refresh. Rather it will do a full page reload

I have added an announcement web App, to SP2013 my team site, and for the App part Ajax option I enabled the following:- Enable Asynchronous Update Show Manual Refresh Button Enable Asynchronous ...
2
votes
1answer
1k views

Update Panel not working in Firefox 2013

Update Panel is not working in SharePoint 2013. It is working in SP2010. In Internet Explorer, it is working fine but in Firefox, the page is refreshed.
2
votes
1answer
790 views

In Chrome, Async Postbacks Fail

In Google Chrome, inside of an Update Panel, the first async postback succeeds, but the second silently fails. The issue is discussed many places: ...
2
votes
2answers
2k views

Ajax web service call not working in chrome browser

Can any point me to the error am doing in this block of code. This is working fine in Internet Explorer and Firefox but not in Chrome. Chrome does not return the result. function ...
2
votes
1answer
2k views

Partial postback sharepoint webpart

I am trying to add update panel to my sharepoint sitepage below: I am getting the error : Failed to load viewstate. The control tree into which viewstate is being loaded must match the control ...
2
votes
2answers
679 views

InfoPath Pop-Up Window

I have a custom Web Part that displays information in an ASP.NET ListView. Upon clicking an item, I need to pop up an InfoPath form via AJAX to edit the item without leaving the page. The ...
2
votes
2answers
33 views

rest ajax sharepoint designer

I am trying to apply and use JQuery news ticker from SharePoint list for which I need to use REST Ajax call, I have tried some codes from net but none of them works, so I am confused where to put the ...
2
votes
0answers
227 views

Copying attachments using JavaScript (JSOM or REST)

I've been able to copy documents in document libraries using the "CopyTo" method: https://msdn.microsoft.com/en-us/library/office/dn450841.aspx#bk_FileCopyTo I'm not understanding how I can apply ...
2
votes
1answer
311 views

Use filtered URL in Ajax call to return JSON data

Currently I am working on sort of a JavaScript function library for all things SharePoint to pass around to some of the SP developers at my work. The idea is to just take some simple features I see ...
2
votes
0answers
782 views

How to properly cache, validate, refresh Access Tokens?

I'm a complete newbie to SharePoint Provider-Hosted Solutions and their authentication logic. My App is an ASP MVC Solution. I run many AJAX-Calls from Client-Scripts to my Controller to interact with ...