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
21 views

How to display Sharepoint online office 365 site in aspx page

I have created an ASP.net web application where I am trying to display a SharePoint Office 365 online site through iframe. I am getting an error XFrame cannot be set to same origin How to ...
0
votes
0answers
14 views

REST API Search images

I'm doing a simple REST request to the SharePoint API and it seems that it doesn't retrieve images or videos, should I add something specific to the query text in order to have images and videos in my ...
0
votes
1answer
23 views

CSR Error: Cannot read property 'style' of null

Trying to color rows based off of the value of the "Status" column However I cannot get it working as it keeps giving the following errors: TypeError: Cannot read property 'style' of null ...
0
votes
0answers
12 views

How to Check if a Sharepoint user is in a security group no matter if this is in a AD group CSOM Javacript

I have a Sharepoint hosted app and I need to check if the current user is in a sharepoint security group no matter if this is in a AD inside the group, the following code check if the user is in the ...
1
vote
0answers
17 views

Refreshing connected child list view after parent update

On my web part page I have 2 list view: Parent and Child. Child is connected to Parent. Parent view is filtered Display=1. I click item "DDD" on parent list, take it to edit, change value Display=0 ...
0
votes
1answer
19 views

SP 2010 CSOM Javascript: Intermittent Failure

I have inherited some JS code that is playing up. It looks something like this: ExecuteOrDelayUntilScriptLoaded(MyFunc, "sp.js") function MyFunc() { var ctx = new ...
2
votes
0answers
36 views

SP.Utilities.Utility.SendEmail with additional headers [javascript]

Want to use the built in SendEmail with javascript and jquery. Found this code and got it working -- sends the email -- using the code below: var appweburl = "https://example.com/site"; var ...
0
votes
0answers
14 views

SharePoint datetimecontrol Date range selection using jquery/javascript?

currently i'm working on SharePoint visual webpart webpart contains two SharePoint:DateTimeControl trying to select a FROM and TO date in range ,The Date Selection should automatically shade or ...
0
votes
0answers
12 views

SharePoint 2010: How to add permission to a folder with JavaScript

I'm trying to create a folder in SharePoint 2010 Library with some modification of the permissions. I would like to remove one group from folder permission (inheritance from library permissions) and ...
2
votes
2answers
37 views

Open the document in the browser

I'm presenting some Search results to the user using REST API, is there something specific should I include in the link to the document so the document opens in the browser?
1
vote
0answers
22 views

Populate multiple text boxes based upon dropdown list selection in SharePoint 2013 on prem

I have 1 main list called OnCallEscalationContacts. This list has fields such as - TechnologyTeam [dropdown], FirstContact [people picker], FirstContactPhone [text field], SecondContact [people ...
0
votes
2answers
47 views

JavaScript not working in Firefox

I have put a snippet of JavaScript into a Script Editor Web Part. It's function is to display an alert box and redirect the page after an Infopath form submission. I got it from this website and ...
0
votes
0answers
13 views

Using JavaScript to create a custom form for a calendar list

I'm designing a device reservation tool on our laboratory's SharePoint site. I created a wiki-page showing all information of the respective device as well as a calendar for the device that shows ...
0
votes
0answers
15 views

how to get client context in a external js file

I have a SharePoint event list where start date and end date needs to be formatted to clients time zone. I am thinking of getting the regional settings and then converting the time. I have to write ...
0
votes
2answers
28 views

GetUserEffectivePermissions returning 0 (“EmptyMask”)

I'm trying to retrieve the current user's permissions for a list but I keep getting an emptyMask result, even when my current user account is a Site Collection Admin. function ...
1
vote
1answer
18 views

To ScriptLink or not to ScriptLink

I need a custom ribbon button that calls a function in a js file in one particular library. To get access to the JS file, I could: Add the JS file reference via a content editor web part on the ...
0
votes
0answers
30 views

How to retrieve webpart xml-definition programatically

I have a Custom Webpart deployed in the Site, to which I need to retrieve the XML definition programmatically using Client side object model, can anybody help? EDIT: I used the following code. ...
0
votes
3answers
28 views

Add javascript in master page sharepoint 2013 using wsp solution file

I added user control and then empty module to reference user control inside SharePoint 2013 master page but it is not working. Control Id="AdditionalPageHead" Sequence="150" ...
1
vote
2answers
40 views

How to get Current Logged Internet Explorer User Name and Domain Name

I need to get user details before hitting the SharePoint Server page. User hitting sharepoint page(https://spxy) then I redirect to https://spxy/_layouts/TestHandler.ashx via httpmodule. I need to ...
0
votes
1answer
30 views

how to change Sharepoint 2013 Default Sign-in Page and create Custom Page (normal.aspx) which redirects users to Http handler(test.ashx page)

Sharepoint Default Sign In page should redirect to my Custom HTTP Handler test.ashx code. I configured multiple claim authentication in sharepoint server 2013 and I need to by pass multiple ...
0
votes
1answer
40 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
24 views

$orderby not working with lookup column Id

I want to sort order my REST results data with a lookup column's Id in my SharePoint list. I tried using $orderby in my REST query, but got no luck. can anyone of you help me out with this ? ...
0
votes
1answer
23 views

Where to store publishing images

I've two site collections: an authoring like portal where authors creates the articles the intranet or publishing portal The articles will be created within a page in SharePoint in this page ...
0
votes
0answers
15 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
1answer
15 views

Javascript code to write JQGrid data to excelsheet?

I am working on JQGrid, I found one solution but it is writing whole JQGrid on excelsheet. But I only want JQGrid data on excelsheet. My JQGrid data consists of sharepoint list data. So can anybody ...
1
vote
4answers
48 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
1answer
26 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 ...
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) { ...
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
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
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 ...
1
vote
1answer
33 views

import sharepoint 2010 list data in json format using javascript (IE8)

i have a sharepoint list already created and populated from an excel file. How would i go about pulling data from sharepoint to a json object in my javascript program. Another requirement is that ...
4
votes
1answer
65 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 ...
2
votes
2answers
313 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 ...
1
vote
1answer
83 views
+50

Hide weekend in calendar SharePoint 2013

I need to hide weekend in calendar SharePoint 2013. And I can hide the columns Saturday and Sunday. But I have some problems in my calendar view. The button "Add" disappears in the columns Friday. I ...
1
vote
1answer
24 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
34 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 ...
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; ...
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
16 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()); ...
0
votes
3answers
40 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 ...
4
votes
1answer
69 views

CSR is also applied to a Group By header in a ListView

The only decent blogs mentioning CSR and Grouping are: http://www.codeproject.com/Articles/620110/SharePoint-Client-Side-Rendering-List-Views (must read) ...
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 ...
0
votes
1answer
38 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
21 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
13 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
24 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 ...