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)

2
votes
1answer
27 views

Top visited entries on site collection blogs

I want to develop a web part which shows the ranking of entries of a site collection. By now, I think a way to do this is to use a Javascript code added on the master page which adds a row to the ...
1
vote
1answer
95 views

Retrieve list status from sub sites using SharePoint Javascript

I'm creating a status page in the site collection that needs to display List Status of all the subs below site collection. All the sub-sites have the same list 'Projects'. So the idea is to iterate ...
2
votes
2answers
148 views

Recent documents for currently logged in user (Client side)

I want to achieve something like shown in Image below. I want to display Recent Document visited by logged in user. I have tried it using Content Search Web-Part. I also tried to achieve it using ...
2
votes
0answers
42 views

Display image(preloaders) before content is loaded WebPart - SharePoint 2013

I'm using a plugin called lighslider and I notice it doesn't display the whole content on first load until I refresh. I have tried using 1. windows.load, 2. ExecuteOrDelayUntilScriptLoaded, 3. ...
2
votes
1answer
131 views

Make a Choice Field-dropdown- as ReadOnly

Is there a way to change the EditForm in my SP 2010 site to display a dropdown column but as Read Only, so the user can not edit that column after the item has been created.I added the below code, ...
2
votes
1answer
268 views

JSOM How to get User Id

When trying to resolve a user with the ensureUser() call, the object is always returned as undefined even though the user exists as a Domain and SharePoint user. //Calling code. var currentCtx = ...
0
votes
0answers
30 views

Code Break Down Help: Start SharePoint Site Workflow btn OnClick

I'm rebuilding a project and I just need help following the previous developers code as I'm new to this. I am aware that this is the GUID for the site workflow: 554AAB6B-5318-4106-BA40-E7336FCE029B ...
0
votes
1answer
113 views

SharePoint custom edit form button javascript onclick set fields value

I'm fairly new to developing and I have a custom form that I made using SharePoint designer 2010 - I need to start my workflow on the click of the button, but I'm not using a site based workflow, so ...
0
votes
1answer
52 views

How to delete a row from an Excel Table using the client-side Ewa object in a SharePoint Excel Web Part

The SharePoint Excel Web Part client side API ,Ewa (https://msdn.microsoft.com/en-us/library/office/ee589018.aspx) does not seem to have any methods to manipulate an Excel Table (i.e. a ListObject in ...
0
votes
0answers
14 views

save a sub-site as a template with content and update URLs when adding/importing

I have a sub-site with: a document library with some JS and HTML files a document library that I've added a webpart to in the EditForm.aspx and DispForm.aspx -- the webpart references one of the ...
1
vote
2answers
112 views

How to get byte array of selected document?

I have a javascript function where I would like to get the byte array of the selected documents. How to do that? function DoSomething() { var context = SP.ClientContext.get_current(); var ...
0
votes
1answer
58 views

JS Link create a Column / read metadata of a document

I'm new to SharePoint and JS Link. I have to read the metadata of a document in a document library. If the document is locked for the current user, I want to create an extra column and display an ...
0
votes
0answers
20 views

How to do a webservice call from clientside in js? [duplicate]

I would like to execute a webmethod in a SharePoint webservice. See extra info below: SharePoint webservice: http://myCompany.com/_vti_bin/Officialfile.asmx Webmethod: SubmitFile How to do this in ...
0
votes
1answer
89 views

How to always open documents in a document library in a new tab for Sharpoint 2013 Foundation

How do i tell Sharepoint to always open documents(mostly .pdf and .docx/.doc)in a new tab when they are saved in a document library? This has been disgussed in another questinon before. I tired to ...
1
vote
2answers
59 views

Prerender executing twice

I have some prerender code that is being used to get information from another list to add into the display of the main list. I am puzzled - the prerender code executes twice. (function () { var ...
0
votes
1answer
28 views

executeQueryAsync doesn't follow success nor fail route

I have the following code: var markup; function generateTree() { var lines = document.getElementById("imputs").value.split('\n'); var targetWeb; var clientContext; var contexto = ...
0
votes
0answers
37 views

Retrieve direct reports to a manager in a SharePoint 2010 list

I need to design a SharePoint(2010) list which automatically retrieves direct reports of a manager and populate them in a drop down and when any of the employee/direct report is selected in the drop ...
1
vote
0answers
16 views

How to get an Excel table's Summary property from JavaScript on the client side using the Ewa namespace

Background: The value of the Summary property corresponds to the setting of the Description box in the Alternative Text dialog box, which is displayed by right-clicking on an Excel table and then ...
0
votes
1answer
220 views

How to set /auto populate Person/ Group field in SharePoint 2013 New/ edit forms using JavaScript?

How to set /auto populate Person/ Group field in SharePoint 2013 New/ edit forms using Javascript? I tried this code and its not working in 2013 <script type="text/javascript"> //fiedName is ...
0
votes
0answers
77 views

CoreInvoke createNewDocumentWithRedirect2 withOut redirect to edit page

How can i use this js code with out redirect to another page after buttonOk pressed ? CoreInvoke('createNewDocumentWithRedirect2', event, '/sites/OAA/test1111/Forms/Document/Doc111111.docx', ...
2
votes
1answer
212 views

filter list record javascript

I am trying to convert c# code to javascript. I am able to get list item using javascript but dont know how to filter. I am aware about caml query but cannot use it here as i need to filter same list ...
0
votes
2answers
46 views

How to put Script Editor inside Content Editor?

I have a javascript and in order to work, I have to use Script Editor. The reason why I want to put Script Editor inside Content Editor is because Content Editor are filled with tables, and 1 of the ...
2
votes
1answer
82 views

Build a SharePoint online app that can create new lists

I'm new to building apps for SharePoint in Office 365. I'm pretty new as a developer as well. I do know that Apps are now called Add-ins, but I'm using Visual Studio and the projects are still named ...
1
vote
1answer
116 views

Retrieving current user's profile picture throws “Access Denied” error

I'm trying to get the current user's profile picture and I'm using CSOM. But I receive an Access Denied error, when I actually gave Read permission to user profile service. ...
1
vote
3answers
270 views

Need to Check Username

In the "Created By"List Column I need to search if Current login user is present or not using Java Script. How can I achieve that.
0
votes
0answers
21 views

Modify People Picker Located in IFRAME on WebPage

I am new to SharePoint and need some assistance. I have a webpage written in normal HTML and JavaScript with an IFRAME that contains a SharePoint page. When the webpage loads, it contains the user's ...
0
votes
0answers
6 views

NamedItems show in a div element

Usually i am working with NamedItems in a WebPart to show them on SharePoint. But I would like to show NamedItems (from a Excel) in a div element with JavaScript or any other language on Sharepoint - ...
0
votes
1answer
50 views

SP13: Custom List Add Item Redirect

This is possible with a SharePoint Survey, but not sure how it's done using a Custom List. I have a custom list and when someone adds an item after they click 'save' it opens to the list library ...
1
vote
2answers
130 views

Programmatically create fields in a SPList using Client Side OM

Has anyone tried with creating some 20+ Single line of text SPField using Client Side OM, like within a Content Editor Web Part. Because creating a SPList with these many number of columns using ...
0
votes
0answers
21 views

Javascript search code really slow in external page only when loaded in SharePoint

A while ago my supervisor asked me to build a tool to display some information from our ERP system. The ERP system is not that great, and often it is easier to just hack together a CGI script to ...
0
votes
1answer
157 views

Validate Choice Field with multiselection Checkboxes on PreSaveAction function Call

My SharePoint 2010 list has a choice column that with checkboxes and allows multiple selections. For all these checkbox field choices there is a corresponding textbox fields are created. This textbox ...
2
votes
0answers
41 views

CSR - One function for every field in a View?

We all know how to define one template function for one field. SPClientTemplates.TemplateManager.RegisterTemplateOverrides({ Templates: { Fields: { "[fieldname]": { ...
1
vote
1answer
74 views

sharepoint profile picture

Is there any possibility to change profile picture or uploading a new profile picture in SharePoint Online by using SharePoint hosted app, via JavaScript or jQuery? How do you solve it?
0
votes
0answers
28 views

Check whether user is active or inactive in Active Directory using REST API or JSOM?

How can I check whether user is active or inactive in Active Directory using REST API or JSOM ?
2
votes
0answers
26 views

How do I restore specific list item version using JavaScript?

How do I restore specific list item version using JavaScript? Is there any way to restore specific version of list item using JSOM or REST API in Share Point?
0
votes
1answer
29 views

Connect to SharePoint data with JS

I have following link that have XML data from SharePoint http://appsrv/pfa/_api/ProjectData/Projects?$select=ProjectName,ProjectStartDate,ProjectPercentCompleted and I have a username & ...
3
votes
1answer
90 views

.find().filternode().each() v/s .find().each()

I came across a lot of articles and discussions by Marc D Anderson and Steve Workman regarding performance gains using .filternode(). I also read an article by Steve Workman I also tried to ...
0
votes
0answers
16 views

SharePoint 2010 Search Results Per Page not exact

I have a page set up with a People Search Core Results webpart on it. When I set the 'Results Per Page' display property to 50 it doesn't show 50 results. It shows 44 or 46 or 48 or some other number. ...
0
votes
1answer
44 views

Quick Launch Menu Selector

The objective is to increase the size of the menu within the fly-out. I applied the script below. The only thing highlight that highlights the menu item when you hoover over does not appear any ...
0
votes
2answers
159 views

Display Description of choice column type on top in SharePoint 2013

I have created a list with type Choice and set Description for the same. I have set Radio Buttons as Display Choices Using. When I click on Add New item the description is shown at the bottom. Is ...
1
vote
1answer
30 views

jQuery Blur function in Content Editor web part in SharePoint 2010 List form

Want to know how to use a jQuery blur function for my SPNumberField, single line of text etc fields.I do not have the ID of the field, also how to get the ID for using the same in jQuery function? ...
0
votes
1answer
53 views

Validation of multiple textbox, number fields using JavaScript

I am doing the JavaScript validation of SP 2010 list mynewcustomform.aspx page using the code written in content editor web part. Fields are: textbox1, textbox2, textbox3. var valoftxt1 = ...
5
votes
2answers
307 views

Null Reference Type Error using Javascript in Sharepoint 2013

Having an issue with javascript in sharepoint 2013. We have set up javascript and it is working by changing the colours of the rows in a task list. The issue is when the user goes into quick edit, and ...
1
vote
1answer
227 views

Programmatically create workflow with JavaScript, JSOM and SP.WorkflowServices.WorkflowServicesManager

I want to create and add a workflow programmatically to a list on SharePoint Online using JSOM (with sp.workflowservices.js). First I created a test-workflow like this using SharePoint Designer 2013: ...
4
votes
3answers
307 views

How can I get two List Items using one Caml Query?

I need to get data from two customs lists that I created. However only the first list item is queried allowing me to use the data in the Home Page list item only, but I need both. var listItems; var ...
0
votes
1answer
152 views

How to set a value in a Choice Field based on the text box change SP 2010 in list newform.aspx

I am having few fields like single line of text, choice field, rich text on my customnewform.aspx of my SP 2010 SPList. Now if I enter a value say USA on the text box, I need to set the ...
0
votes
2answers
35 views

Using javascript and Jquery widgets in Visual Web Part. Is it posible?

I am trying to build a Visual Web Part in Visual Studio for Sharepoint Foundation and I am wondering if I can use Javascript for some functions and jquery widgets to create a listbox? I have tried but ...
1
vote
3answers
111 views

How to insert data into lookup column using javascript

I have created a custom drop-down list and inserting drop-down data into lookup column(in a list). How to insert drop down data into a look up column? I am trying below code but it is not working. ...
0
votes
1answer
163 views

Make promoted links responsive

I have managed to add some JavaScript that I found here and almost get my promoted links to be responsive. The only issue is that when my screen gets below a resolution of approximately 900px the ...
0
votes
1answer
238 views

Using the variable of .aspx code in .js code

I have one variable in .aspx code and i want to use it in my .js code. How to make this work? In .aspx code.. var url = document.referrer; var res = url.split("?"); var str = res[1]; So I want ...