Javascript is a dynamic computer programming language, most commonly used as part of web browsers, whose implementations allow client-side scripts to interact with the user, control the browser, communicate asynchronously, and alter the document content that is displayed.

learn more… | top users | synonyms (2)

0
votes
1answer
42 views

how to by pass multiple claim authentication login page in sharepoint 2013?

My Requirement is I have sharepoint server 2013 .Now I just added two AD FS Server 3.0 and configured to sharepoint site http://spsxyz with Claim based authentication. Example of My Server Setup: ...
0
votes
1answer
18 views

Add Web Part to page “automatically”-Sharepoint foundation 2013

I'm a relative Sharepoint newbie trying something that seems like it should be simple but having lots of trouble executing it. My organization does not have much more sharepoint experience than I do ...
0
votes
0answers
16 views

'SP.ClientContext.get_current' is null or not an object

I have created a javascript script ih the Home.aspx of sharepoint foundation 2010 (exactly in a web-content editor). I keep on getting always the same error:'SP.ClientContext.get_current' is null or ...
0
votes
1answer
21 views

How to make page that redirects dynamically based on URL

Sorry for bad title, I really don't know how to describe this problem. Any suggestion is welcome. I have to implement one custom button in ribbon bar in all documents to move files from one doc lib to ...
1
vote
4answers
51 views

after clicking the cancel button close the popup window and redirect to parent window

I had a requirement in my code as follows After click the cancel button in the sp model popup window it should be closed and redirect to the parent window.
0
votes
0answers
14 views

Can SharePoint objects like 'SP.ClientContext' be used while developing Office 365 Mail Addin in Napa?

I am developing a Office 365 Mail Addin in Napa. I am trying to use the object of SP.ClientContext but it shows me error that SP is not defined. Office.initialize = function (reason) { ...
5
votes
6answers
8k views

Enforce Drag and Drop documents to apply metadata

We have implemented an issue management system in SharePoint 2013 which provisions a page for every issue added to a specific list. One of the Web Parts the automatically provisioned page contains ...
0
votes
1answer
27 views

The condition Greater Than (>) cannot work in my jquery code [closed]

I need to check the number of characters in class span, then change CSS according to the number. For example, if length of title is less than 29, the title color should be yellow. If length of title ...
1
vote
1answer
530 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.
0
votes
1answer
17 views

How to select entire texts in class span [closed]

I have an array title value with the class .block .title h2 span, I want to select entire texts in this class and check every title length. my script is x=$(".block .title h2 span").text()[i]; ...
0
votes
4answers
1k views

get the attachement files from REST API

I use REST API SharePoint 2013 to get the items from list: And and I want to get the Attachments Files, How can i do that? This the code : function getListItems(url, listname, query, complete, ...
0
votes
0answers
32 views

Create Web Property in Web Property Bag in SharePoint Site using REST API

I want to add one Web Property to sharepoint sub site using REST API. Is it possible or feasible using REST API?
0
votes
0answers
18 views

Load javascript file on wopiframe.aspx in SharePoint Online

Is there a different way to load external javascript files on the WopiFrame.aspx / Word Online / Excel Online page? We are using SharePoint Online. I have some external javascript files load with our ...
0
votes
1answer
550 views

SharePoint 2013 custom Attach File button

I'm trying to create a custom "Attach File" button in my SharePoint 2013 New Item form. So far this is what I've done: HTML <div onclick="javascript:openpageindialog();" class="btn" ...
0
votes
1answer
47 views

Approving the filtered values of list using javascript

I have a list, a list filter and two date filters(Start date and end date) in a page. First I have to filter list using this filters and then I have to approve whatever item are left in the list after ...
4
votes
1answer
66 views

executeQueryAsync callback with a while loop

I am fairly new to javascript and have spent some time trying to understand callbacks as they relate to SharePoint's CSOM, but have had some issues. Essentially, I am running a query to get a ...
0
votes
3answers
42 views

change server date time to local date time

how to change the server date time to local date time using javascript. I am using following function for getting the server time.Now i want to change this time to local time zone. function ...
0
votes
1answer
36 views

getItemByID is not a function

I have the following script that is returning the error message "list.getItemByID is not a function" and I can't figure out why. All examples use this function. I am trying to iterate through ...
2
votes
2answers
316 views

Calculate age (YYMMDD) date

I've managed to calculate age using only "Year", but I would like to know how you can do this using a complete date ( YYMMDD ), This is the code I used to calculate age using only year: function ...
3
votes
3answers
2k views

How can I implement SharePoint JSGrid filtering and grouping functionality?

I am working on SharePoint JSGrid. I am able to implement the sort functionality in JSGrid. Now I want to implement the grouping and filtering in my custom JSGrid. For filtering we have to attached ...
0
votes
1answer
1k views

Upload a document in a specific folder

I would like to set a specific folder when I open the upload.aspx page to help. I tryed to look in the dll but the license of reflector is expired. UPDATED Maybe this post can help ...
0
votes
0answers
20 views

Error-The request xml is too complex and its depth exceeds the maximum depth 32 undefined [duplicate]

I am getting this error while running the below javascript code. <script type="text/javascript"> //var siteUrl = '/projects/SharePoint2013-Demo/TimesheetManagementSystem/'; var oList = null; ...
3
votes
1answer
3k views

Getting Version History and What Field has Changed

I am using the GetVersionCollection to get the history information from my list. This seems to be working fine; however, what I need to do is get the version history of the individual item which has ...
2
votes
1answer
103 views

Query Pages using REST

I've developed a newsfeed app part that currently gets its information from a list, however we're keen to have article pages that we can click through too. So far I've not found anything in the REST ...
1
vote
1answer
25 views

Presenting calculated age in textbox

I've calculated the age using setFullYear and getFullYear, as I only want to use the birth year to calculate age for fun, but it doesn't work Here's the code I've tried so far, which I think should ...
0
votes
1answer
38 views

JavaScript runtime error: Object doesn't support property or method 'add_requestSucceeded' in Sharepoint 2013/ SharePoint Apps

I am new to Javascript and Sharepoint 2013. I am following a tutorial and I created a lab exercise, in it I am adding a new item/record/row in a list via Javascript. In this example the list is ...
1
vote
0answers
16 views

Sharepoint 2013 Notifications (Similar to Outlook)

I have a SharePoint 2013 on-premise intranet portal. I want to build a Notifications feature similar to the one in Office 365 or something similar. Anyone got recommendations on using 3rd libraries ...
0
votes
0answers
18 views

SPUpdateMultipleListItems not working

I am trying to update a column in a list, changing all the items to Approved. Below is the script i am using. function approveall() { alert($().SPServices.SPGetCurrentSite()); ...
3
votes
1answer
551 views

how to find out when a user last visited?

I'm trying to figure out when a user has last visited.So let's say I logged out of my SharePoint intranet last night at 11PM, and this morning I logged back in at 9AM, I'd like to see a message saying ...
0
votes
1answer
43 views

Prepopulate NewForm.aspx Lookup DropDownList SharePoint 2013 with Javascript

In SP2010 I used the following JavaScript(JS) in a Content Editor on the NewForm.aspx page. This was used to prepopulate a lookup dropdownlist with a value from the Query String Parameter. Now that ...
0
votes
1answer
22 views

Check field change in own edit form

We have a list with 3 different textfields (textfield 1, textfield 2, textfield 3) and 3 different datafields (datafield 1, datafield 2, datadiels 3). We work with a own edit-form. Now i want to add ...
0
votes
0answers
53 views

Adding a custom ribbon tab breaks grouping by function in sharepoint list

So, I found this tutorial online as to how to add a ribbon tab in sharepoint 2013. While it works, whenever I add an OOb library or list and use grouping in that list, the items cannot be expanded but ...
0
votes
0answers
14 views

How to use SP credentials to authenticate user for external WCF service by javascript

I have an application page in SP with javascript and by this javascript code I'd need to call external self hosted WCF service from different domain with some authentication.(The WCF service is able ...
1
vote
1answer
26 views

ResetRoleInheritance problem

Im trying to reset a list's inheritance using javascript and Sharepoint 2010. Here is my code so far: <script language="JavaScript"> <!-- var vcms_currentCTX; var vcms_currentWEB; var ...
0
votes
0answers
12 views

Code for Spotlight Web Part

Working in SharePoint 2013 and not able to use all the cool (free) apps offered because of internet security reasons. I really like the Spotlight App (image below) so I am trying to create it without ...
0
votes
0answers
13 views

Not getting [Object File] from a File Input HTML Control using JQuery in WebPart Custom Page

I am Using SharePoint Designer 2010 I have a file input control and a button as below: <input type="file" name="Resume" id="upload"></input> <input type="button" id="btnSave" ...
0
votes
3answers
46 views

Hide columns in display form based on a value

I have the below javascript to hide columns in New/Edit form: jQuery(document).ready(function($) { if ($("select[title='Column1']").val() == "Value1") { ...
1
vote
1answer
1k views

How to upload image file into the SharePoint 2010 picture library using javascript

I need to upload image file to SharePoint 2010 picture library using javascript. The requirement is: We have File Upload control Ee have to upload image file from that file upload control My code ...
0
votes
1answer
18 views

Enumerating contents of 'context.load' JS object works but using 'getById' does not work

In my Office 365 App I have a simple functionality where it loads a library and then reads a couple of fields for all items in the library. Below is my sample code: (function () { ...
0
votes
1answer
782 views

Hover effect over an image in SharePoint 2010

I would like to add a kind of hover effect over an image. My source code in JavaScript looks like the following: _spBodyOnLoadFunctionNames.push("color"); function color(){ var $th = ...
0
votes
2answers
3k views

Trigger JavaScript on Custom Action Ribbon/Menu Item

I have two custom actions that are currently deployed to a SharePoint 2013 Forms Library. They are working perfectly fine with the exception of a less than favorable method. What happens now is that ...
2
votes
1answer
43 views

Need to change the value of a drop down choice box

I have a list in sharepoint. One column is a choice box for pending, approved, denied. I need to create a method to approve all on the click of a button. I cant figure out how because it doesnt ...
0
votes
0answers
21 views

Automatically schedule a page on publish - JSOM

i recently came across this link where the item scheduling is done using server side code Automatically schedule a page on publish I am looking for the javascript equivalent implementation of the ...
0
votes
0answers
12 views

Add sitecolumns to contenttype using csom sharepoint (loop)

I try to add a couple of fields to a content type. Sometimes I get the error: The object has been updated by another user since it was last fetched. What I've done (simple version): lets say ...
1
vote
1answer
15 views

Accessing the OnSuccess event for AJAXRefreshView

I am doing a AJAXRefreshView on a particular site page after a button is clicked. The list in question is being refreshed however I am unable to apply some custom styles that have been applied to the ...
0
votes
0answers
18 views

Can I customize Alert Me setup dialog

I am working on SP2013 on-premise standard edition. When clicking "Alert Me" button on ribbon, the default SubNew.aspx form will be called. I need to customize the form a bit so that: When setup ...
0
votes
0answers
12 views

how to delete a sealed field

How can I use Lists.asmx?op=UpdateList and JavaScript to delete a sealed field? My code works to create/update fields. I used it to create a sealed field. Then later I'm trying to delete it but it ...
0
votes
0answers
18 views

REST Look-up Field Expansion (Members Unknown)

Trying to expand a look-up field, in a REST call, without knowing the member names. For example, I have a custom list with a People Picker field (Employee). I can retrieve the Title and ID fields via ...
0
votes
2answers
10 views

Create a Homepage for TeamSite with SharePoint 365

What I am doing is to set the Home.aspx as the Homepage for my TeamSite. I've added a Web Part as Script Editor and put the jQuery script as below to remove or hide the left menu and the Home. ...
0
votes
1answer
57 views

JS Link View Overriding for date

I have a date column in my custom list. When i try to override the view of the field by using the TemplateOverride Function, my Javascript wont work on! The same problem occurs for Multiple Choice, ...