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)

3
votes
1answer
149 views

Security Error while doing REST update on the SP list

I am trying to make update with the usage of REST but I got an error: -2130575251, Microsoft.SharePoint.SPException. The security validation for this page is invalid and might be corrupted. ...
2
votes
1answer
66 views

Async REST Queries and setting field values to global variables

I'm having a problem wrapping my head around these sharepoint async REST queries. The problem is that an async REST query isn't setting a field.value because the assignment is happening to soon. Even ...
3
votes
2answers
197 views

Object Doesn't support property or method '$1X'

I am using JSOM in Nintex Forms 2013. My script includes are /_layouts/15/sp.runtime.debug.js /_layouts/15/sp.debug.js /_layouts/1033/init.js /_layouts/MicrosoftAjax.js /_layouts/sp.core.js /_layouts/...
2
votes
1answer
67 views

How to handle & and + characters in hyperlinks in the search People hover panel template

In our SP Server 2013 environment we have an employee directory. The hover panel that shows up next to a result shows the Department name of an employee. This is a clickable hyperlink. When a user ...
0
votes
1answer
148 views

Problem with retrieving Sharepoint list with js

I am trying to retrieve list from SP page but I got following error: Uncaught TypeError: Cannot read property 'apply' of undefined from MicrosoftAjax.js file. It seems that it's due to the ...
1
vote
1answer
287 views

How can I run JavaScript after saving SharePoint list item properties from editform?

I have some code I want to run on a list item after any properties (metadata) are saved from the editform window. Where/how can I put JavaScript to run at that time? Thanks!
0
votes
2answers
45 views

Broke my SharePoint site by modifying master page, help!

I was attempting to add Javascript that would remove the "recently viewed" list of the SharePoint page. I ended up removing the code, and upon saving the page and navigating to the SharePoint site, I ...
1
vote
1answer
929 views

Uncaught ReferenceError: SP is not defined

I am trying to implement to Sharepoint simple function from MSDN which I've placed in aspx file but I got this error in js web browser console: Uncaught ReferenceError: SP is not defined. Any ideas ...
0
votes
1answer
408 views

Compare two int columns in a Sharepoint list

I´m doing a course catalog app for SharePoint. And I have a list called Courses. In that list I have two columns called: Seats and FreeSeats. When you make a new course the boss decide how many can ...
0
votes
4answers
132 views

How to retrieve and read items from sharepoint list and assign them to a variable with JavaScript?

I have the following list how can i retrive the value of koha column for first row and second row separate, datatype for koha column is number and how to assign value of koha into a variable var ...
8
votes
1answer
290 views

HierarchyRequestError in sp.ui.rte.js

How can I resolve this error? I see this in Firebug's Javascript Console for sp.ui.rte.js on every Sharepoint Page that's loaded. It persists through an iisreset. And it is always the very last ...
3
votes
4answers
929 views

Getting Value of Radio Button on SharePoint 2013 Edit Form using jQuery

EDIT: updated verbiage to reflect this is specifically a Radio Button choice field. The below script works when the choice is set to display in a drop down. I'd like to be able to do the equivalent ...
1
vote
0answers
29 views

How to put onload events on SharePoint 2013 scriptlinks?

In my page layout, I want to load a javascript file and put a onload event on it like <script onload="console.log(this)" src="https://ajax.googleapis.com/ajax/libs/jquery/1.11.1/jquery.min.js"> ...
0
votes
1answer
247 views

Adding a “read more” button to announcements web part with JavaScript

Having some trouble adding a "read more" button to an announcements webpart in SP2013 Foundation. This "read more" button is automatically generated by JavaScript after the announcement/news entry is ...
0
votes
1answer
54 views

Not able to fetch Term store and related terms using JavaScript

I want to fetch termstore, Termsets and related terms. However, I'm not able to fetch the termstore. I'm receiving the error message: 404 not found This is the code I'm using: <script src="...
0
votes
0answers
21 views

How to convert an item that is retrieved from list to a string datatype?

I am having problems with some strings i have the following code in javascript: _result = currentQuizItem.get_fieldValues()["Audience"]; "Audience" is a column in my sharepoint list, and it has ...
0
votes
0answers
38 views

assigned to getLookupValue() returns the wrong value

I am working on a SharePoint hosted App where I load tickets for a customer that is assigned to a technical engineer with csom. On start of the app the engineers are loaded correctly but by some ...
0
votes
0answers
26 views

Removing automatically generated file links from SharePoint 2010

I am trying to prevent a page in SharePoint 2010 (specifically a list view page) from automatically generating links from UNC file paths that are entered in a field. This is entered into the field... ...
3
votes
2answers
136 views

How to seen all JSOM internal fieldnames not DisplayName of Column of the list?

I know to get the Internal Fieldname from URL. But that takes long time and status bar is not always full with the url, so you have to open ze field and see in the top url what the internalfield name ...
0
votes
1answer
123 views

Update a colume in SharePoint 2013 with the current date on a daily base

I am trying to update the date of a column to show Today's date and automatically updating one per day in SharePoint 2013. Could someone help? A front-end or client-side approach would be best.
0
votes
0answers
35 views

How to add permission to a site collection?

I have a solution that is built with Visual Studio and I have no permission to delete a list or modify a list. I can not even see the lists that are inside current solution. so i cant access to ...
0
votes
4answers
188 views

Getting Current User - On Page Load (JavaScript)

Basically, what I want to achieve is to hide particular elements in all SharePoint sites within a single farm. What I did is I created a SiteCode.js file inside the Site Assets folder and filled it ...
2
votes
2answers
41 views

Trouble updating rows of data in an External Content Type using Javascript

I've tried a few different ways of doing this, including querying the External Content Type and then updating the current item. However as far as I ever get is an undefined variable error. This is my ...
0
votes
0answers
56 views

Add item level permission

Problem : I have two groups Visitors and Owners. I belong to both group with Full access. these two groups have been inherited to a list and list items level. Now while I want to submit any item to ...
2
votes
1answer
2k views

Get a list Id using javascript?

I'm trying to trigger the NewForm.aspx of a list by clicking on a link. I would like to known how to get a list ID using JavaScript (Or jQuery)? (SP2010) I've already tried : var context = new SP....
0
votes
1answer
46 views

Show one List field Text over an image

I have set an image inside a <div class ="Image"> to display. Now, I want to show one field from my SharePoint List column which is of date type over the image at the bottom position. Can ...
4
votes
2answers
196 views

how to get a list's add new item URL with JSOM?

I'm trying to figure out how I can get a list's add new item URL using JSOM in SharePoint 2010. This is what I have so far to get if the current user has edit access on the list. ...
0
votes
0answers
33 views

Profile properties web part

On my site, on the out of the box web part that shows profile info properties like title, department, phone etc. Is it possible to edit the display name of the properties ? I.e I am trying to rename ...
0
votes
1answer
54 views

Can i query list items from another sharepoint instance with a different domain?

Our parent company shares the same network as us however we have a different SharePoint instance. We are trying to dynamically pull some content from their instance via JavaScript or some other method....
2
votes
1answer
76 views

Can get User Department via JSOM or REST (no UPA)?

The farm has not UPA service deployed and I wouldn't do it. Is it possible to retrieve using JSOM or REST one of the properties that we see in the _layouts/15/userdisp.aspx? page for a specific user? ...
1
vote
2answers
53 views

Is it possible to retrieve lists with specific template?

Is it possible to retrieve lists with template "Custom List" and display it in a jqxListBox or div?
0
votes
0answers
49 views

How to convert a type to Number in JavaScript from Sharepoint

I have the following solution, this is my SharePoint list and here is my UserInterface xhtml and form and here is the problem, when i retrieve this field "koha" using the follwoing code: it ...
2
votes
2answers
667 views

How to extract the user name from ctx.CurrentItem.Author?

I'm customizing the DisplayForm with jslink and like to know how to treat the field Author and extract some informations. For example, the object ctx.CurrentItem.Author returns me this string: 10;#...
1
vote
1answer
103 views

How do I get selected item from a JqxListBox? [closed]

How do I get selected item from a JqxListBox? When I click on list item it should alert me selected item but instead it returns undefined. thx! my code: function onS() { var listString = new ...
1
vote
1answer
556 views

How get item ID in JSLink on DisplayForm

I'm customizing the DisplayForm of a list, and I want put a button on footer to EditForm, but in the ctx has no edit form url and no CurrentItem.ID. How can I do this?
3
votes
1answer
75 views

How to edit the item name in Edit Control Block(ECB) using javascript in sharepoint

I want to edit the item name (Edit Item) to custom name (any) in Edit control block (ECB) of list using JavaScript or jQuery in SharePoint.
2
votes
1answer
182 views

how can i have date range for datepicker (date field) - when submitting form sharepoint list 2013

When users are selecting a date i want the date to be between a range. e.g they can only select from 1st jan to 2nd march nothing else. Is there a way to be able to add this into the date field?
0
votes
1answer
120 views

Redirect New (+) button of Document Library to new upload form of Sharepoint

How can I redirect New (+) button in document library of SharePoint 2013 to a new form to upload file. One more thing is that I have added some columns in the Library and its available in the "All ...
0
votes
1answer
451 views

Include JS Files in JS Link File

Is there a way to include another .JS file into a JSLink file? I have made mini framework to render list views which I want to source out in a seperate file and then add a normal JSLink file for ...
1
vote
0answers
52 views

How to display a message is SP2013 with Javascript? [closed]

I have the following code and what I want is to show a message: function startTimer(duration, display) { var timer = duration, minutes, seconds; setInterval(function () { minutes = ...
0
votes
1answer
140 views

Edit Calculated Column Formula with jQuery or javascript REST JSOM

Is it possible to insert save a formula into a column within a list in list view using jQuery or JavaScript?
1
vote
0answers
174 views

Can you connect Active Directory to SharePoint via JavaScript/ SPServices/ or SOAP?

I am trying to connect a AD to a SharePoint 2013 list form so that the SharePoint form is filled in automatically with data from the Active Directory (i.e. contact information). Is this possible? I ...
0
votes
1answer
24 views

Download the Monent.js to the SharePoint server

Could some on guide me as how to download the Monent.js to the SharePoint server? I know that I can reference it, using <script src="//cdnjs.cloudflare.com/ajax/libs/moment.js/2.7.0/moment.min....
0
votes
0answers
468 views

Javascript window.location.href not working

I am trying to redirect to another site (say www.google.com) from a SharePoint site. I tried using window.location.href and window.location.replace but it doesn't work. It adds the URL to current ...
0
votes
0answers
26 views

Re-direct New Form submission in SP 2013

I am trying to redirect a 'NewForm' submission to another page (not the default list view which is normal behavior). Code like what I've pasted below has worked in the past in SharePoint 2010. It is ...
0
votes
2answers
213 views

Looking for count down clock in CEWP using html/jquery [duplicate]

I am looking to insert a count down clock in content editor web part using html / jQuery. Did any one ever do this? I am unable to figure out how to start as am not a pro in scripting.
0
votes
0answers
32 views

consuming html content of external web application into sharepoint masterpage

I could consume the content (html and css) of an asp.net application from another application with the following Jquery code(I used CORS) : $("#success").load("http://localhost:50710/ .round", ...
2
votes
3answers
193 views

how to get a value from a Sharepoint list with javascript

I have the following code: window.onload = function () { var setTime = // i dont know what to do here var fiveMinutes = 60 * setTime; display = document.querySelector('#timer2'); ...
0
votes
1answer
94 views

How to reference SharePoint list in external website?

I have an external website that is pretty much a form that interfaces with another enterprise software. One of the requirements of the fields in the form is to provide a location. We have the list of ...
0
votes
2answers
113 views

Sharepoint 2013 Custom List Calculate difference between Today and Column Value

I'm attempting to use update a Column [Days Since Last Contact] by calculating the different between =TODAY() and a Column [Date of Last Contact]. I've been trying to use [Day Since Last Contact] as ...