Questions tagged [javascript]

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.

0
votes
1answer
31 views

Make web part compatible for IE11

I have a web part that works for every browser but not in IE. It seems to have troubles with "startsWith" which is a function that is not supported in IE11, fair enough. But when I changed the code ...
0
votes
1answer
19 views

Getting undefined when using getEnumerator

I'm calling a function to enumerate through a list of items with a particular ID\foreign key. When there are no items listed I get the appropriate response back, however, if any records are available ...
0
votes
1answer
10 views

SP13: Linking to Network Drive on Team Site

Normally, I can add a link that points to my network drive from my team home site quick launch with no issue. Not now. I add a the link to my network drive to a folder and will not open. I know the ...
0
votes
2answers
43 views

Front-end connection between two site-collections

I have two site collections on the same farm (on-prem SP 2016), but different domains (business.* and projects.*). I have full control on both sites. And yet, I cannot access one from the other. I ...
0
votes
1answer
17 views

Assigning Task to Group using REST and SharePoint JavaScript API

I found myself in an unfortunate position of being unable to use SharePoint Designer to build workflows and thus am having to rebuild an approval workflow in JavaScript. I am using REST to insert a ...
0
votes
1answer
62 views

Hover images(Enlarge image on Mouse Hover) from SharePoint list 2013

We had SharePoint list with image column. Our request, when some one keep mouse on image column, picture need to enlarge(hover). Can someone suggest direct how to achieve with code. Thanks in advance ...
0
votes
0answers
30 views

How do I bring the Rating Feature from Share Point to my website

I have created a coupon page and I would like to implement the rating feature Share Point offers. I created a Rating Column in my list and then made an Ajax call to retrieves all the items from that ...
0
votes
0answers
15 views

call c# method in javascript sharepoint 2016

I have a Rendering template list view created using JavaScript and i have c# class method. How can i call the c# method in JavaScript or how to include the assembly in the Javascript?. Thank you.
0
votes
0answers
14 views

How to show lookupcolumn field data in custom form field

Created a lookup column in my sharepoint list that fetch data from different list Now i created a custom dropdown fields i.e, <select id="test"></select> How i will display the dropdown ...
0
votes
1answer
13 views

How do I filter elements from a Share Point list by category in Java Script

I have a created an accordion that has 7 different categories (Auto, Entertainment, Health and Beauty, etc). The content of each category lives in a SP2013 List; each list item was given the ...
0
votes
1answer
27 views

How to access Everyone But External Users via Javascript in SharePoint Online

When adding a group to a site via Javascript, I know you're supposed to use the group ID - but if I want to add "Everyone except external users" to that site with Read permissions, what ID do you use? ...
0
votes
1answer
37 views

Jquery Validation Plugin Error This[0] is undefined - Sharepoint Online Add-in Development

I'm development a Sharepoint Hosted Add-in in Sharepoint Online tenant. I'm using Jquery and Jquery Validation to make form validation, but I have a issue with JQuery Validation because of get error ...
0
votes
1answer
18 views

how to get people picker field value and store it in a variable

i have a small requirement where in, i have a column "Employee Name" as a people picker field, now i just want to retrieve the employee name value in a variable after the user has entered his name in ...
0
votes
0answers
7 views

Comparing changes in multi-value fields in a better way in SharePoint Online

We have created a user database and as part of this we have a few multi-value fields in the SharePoint List. When a new value is added to the multi-value field we use the versioning to see which of ...
2
votes
1answer
42 views

Check if a user is a member of SharePoint group JS REST API using async await

How can I check if the current user is a member of a specific SP Group using REST API and async/await? _spPageContextInfo.webAbsoluteUrl + "/_api/web/sitegroups/getbyname('" + grpName + "')/...
0
votes
2answers
40 views

How to SP2013 list put it into DataTable dynamically?

I have a sharepoint 2013 list with some items, I need to put it into DataTable dynamically, is possible create the html table automatically?
0
votes
2answers
33 views

SharePoint Custom Webpage/Part Not Consistently Loading

I hope this is the right place I have been in a role within my organization working with SharePoint for a couple of months now, so i'm a newb more or less. I have some experience (again a novice) ...
0
votes
1answer
33 views

Retrieve users info with js and sharepoint

I am facing following issue: I need to retrieve users from the whole domain not just siteusers list at sharepoint so that can can manipulate them and for example add them to sharepoint groups. I ...
0
votes
1answer
31 views

Freeze First Column of Sharepoint online List view using Jquery/javascript [duplicate]

i want to fix first column (ex: Title column) of my sharepoint list view, so that whenever the user scroll horizontally the first column should be fixed. Thanks in advance for your support.
0
votes
1answer
45 views

Only Showing Timeline in Task List

I know how and find many ways how to hide the timeline from the task list but I don't find where I can just show the timeline and hide everything to the list. Question: What can I do to show the ...
0
votes
2answers
21 views

Connected Excel Spreadsheet to SharePoint List

Here is what I have done and what I am trying to do. I have a SharePoint list that I exported to Excel and then created a connection. When I add an item in the SharePoint list the new items are ...
0
votes
0answers
13 views

SharePoint 2013 Hide list row based on another list with javascript

I have two lists, Parking Slots and Reserved Parking. Reserved Parking has a look-up column (Slots) from Parking Slots. I have a page where both lists are displayed. What I need is a javascript ...
0
votes
1answer
18 views

Javascript to read site collection storage volume

It is possible to read the storage Volume of a site collection with JavaScript?
1
vote
1answer
48 views

javascript not working first time after iisreset in a visual web part

I am having a bug in one of the visual web parts. First of all, this is not my code and I am not an expert in javascript. Secondly, this issue is only happening the first time after the pool has been ...
0
votes
2answers
32 views

ctag parameter is getting added to js file on web page Sharepoint online

I am working on CEWP.when I am trying to debug the javascript file.On button click i called a function but function is not getting called becos js file not loaded properly .At the end of js file some ...
0
votes
1answer
19 views

How to log data to a database using javascript?

I am to track who viewed a specific document in a document library, I found out that there is no Item Viewed event or similar event in the SPEventReceiver class. SO I developed a spfx solution that ...
0
votes
0answers
28 views

How to attach SP date picker to text input via javascript?

Created a web part page to test initializing SharePoint controls via javascript, can't get the date picker working. Its been driving me nuts for hours now. Anyone see any obvious mistakes? <input ...
0
votes
1answer
42 views

Inserting dynamic data in a sharepoint list using jsom

I am trying to insert dynamic data (question number, question and answer checked) to a new sharepoint list. The data needs to be read from another list, i.e. "Questions1List". I have a quiz page in ...
0
votes
0answers
48 views

Inserting multiple rows in a SharePoint list using JSOM

Hi I am trying to insert the data in the form of multiple rows to a SharePoint list. I retrieved question number, question, choice answer options as shown in image. Now, I want to insert the question ...
0
votes
1answer
22 views

SP.js loading issue while retrieving list items using JSOM

Hi I am trying to retrieve list items using JSOM. But, the problem occurring is that SP.js is not loading correctly. It shoul load before the function gets executed. I am confused about where to use ...
0
votes
0answers
30 views

success call back or REST call not firing

Successfully adding items to a list but success handler not firing. Anybody know why? function addListItem() { var guidance1 = $("#guidance1").val(); var guidance2 = $("#guidance2").val(); ...
0
votes
2answers
90 views

How to get email of user's domain name via javascript?

I am looking for a way how to find some users emaill address based on their domain id. I found many solutions for Current users via user = clientContext.get_web().get_currentUser(); however i want ...
0
votes
2answers
76 views

How to add JS validation on SharePoint new item form to check date field populated or not

I am working with a Task list in SharePoint online. On the new item form, I have a field called 'Due Date' (Internal name: DueDate) which is set to optional and for one of the Flow requirements, I ...
0
votes
1answer
28 views

The property or field has not been initialized when setting a lookupfield id on another field

My snippet code below. What i'm trying to do first is be able to update batch items with large number of items(THIS WORKS) and in between be able to get a lookup id field from one of the fields and ...
0
votes
0answers
11 views

Unable to pull in current item on EditForm.aspx using StratusForms

I'm using StratusForms for a SharePoint 2016 classic application (system admin won't enable modern pages) and was able to successfully use a CEWP on NewForm.aspx to contain my code and submit to my ...
0
votes
0answers
10 views

How to save to a richtext column using TinyMCE

I'm trying to make a custom form using js and TinyMCE, and the problem I have is that all of the rich text is saved, except the images, when I check the list, the html is saved like this <img alt=...
0
votes
2answers
28 views

Help stopping a SharePoint Workflow with JavaScript

I'm attempting to write a script that will cancel and start workflows when an error happens. I found this section of code on different sites but have not been able to get it to work. After stepping ...
2
votes
1answer
41 views

SharePoint online TextEditor Option for Javascript and other code no longer available

I have noticed a recent dramatic change in SharePoint online. I have multiple java script and html scripts that control content editor webparts on my SharePoint site. Previously I could view and ...
0
votes
0answers
9 views

Apend a text from a PoG or CalculatedValue to a text single field

I am trying to append a text from a People or Group (varRecipientName) into a Single Field text (.CollectedByUserClass) when a dropdown changes. I tested it with the below code which works when ...
0
votes
2answers
97 views

Unable to get property 'createRange' of undefined or null reference

I have a SharePoint custom list form with a bunch of Javascript running on it. In particular I have one field where it gets its choices from a lookup to another list. The lookup returns n versions of ...
0
votes
1answer
23 views

JSLink not modifying text

I am trying to get a super simple JS script to work on my SharePoint. I found this example here. This is what I am working with: (function () { var statusFieldCtx = {}; statusFieldCtx.Templates = {}; ...
0
votes
3answers
76 views

SharePoint 2013 - Copy People Picker Field to Text Field

I need a way to copy what users place in a People Picker field (single selection only) and place it into a single line text field. I'm not allowed to user Designer so this can only be done with ...
1
vote
1answer
33 views

Get person display name from list via javascript

I am facing problem that i cannot solve. I have a function which works properly but returns number id of user from sharepoint not display name. Here is the function: function getItems() { $.ajax({ ...
0
votes
1answer
23 views

Removing elements with javascript

I have a SharePoint modern page that I would like to customize with javascript or CSS, is this not possible? I want to remove the top bars and the bottom as well, so that I pretty much have a blank ...
0
votes
1answer
25 views

How can I send the results from a form (with HTML, CSS, JavaScript, JQuery, etc.) to a Sharepoint Library

I am trying to create a form with html, css, javascript, jquery. Basically, what I would like to do is, when the user clicks on the "Submit" button, the values entered in the form will be send to a ...
0
votes
0answers
66 views

Uncaught TypeError: Cannot read property 'wpq' of null

Uncaught TypeError: Cannot read property 'wpq' of null at NewOrEditV4Core (core.debug.js?rev=EW80nTQ9XTlOZU%2FEGCD2cg%3D%3DTAG0:4374) at _NewItem2 (core.debug.js?rev=EW80nTQ9XTlOZU%...
0
votes
0answers
19 views

Ordering numbers in SharePoint using JavaScript?

We have a lot of documents given an [Issue Number] which goes in such fashion: 1.1.1, 1.1.2, 1.2.3 ..... 1.1.9, 1.1.10 When ordering by the Issue Number then the 1.1.10 is ordered underneath 1.1....
0
votes
1answer
24 views

Javascript to auto fill data in new form from the previous entry

I want to auto fill the entries in form fields from previous entry in the sharepoint list What I done is I created a new request from my custom form page and submit after that the data added in ...
0
votes
1answer
70 views

SharePoint 2013 - Get sum of number fields and lookup field with Javascript

I'm creating a list that helps track employees projected hours they spend on projects as well as holiday, training and vacation hours. However the holiday field is part of a look up from another list....
0
votes
2answers
39 views

Get value from Column and cut the duplicates using SharePoint Rest API

I've multiple folders inside the pages library Within each folder I have pages Grupo de produtos is of type taxonomy. I run the function GetPagesProd and for each item I get the value from Grupo de ...