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
0answers
75 views

SP2007: Parsing GetUserCollectionFromSite response

I'm writing a javaScript that has the person name and calls GetUserCollectionFromSite to fetch the user's account name (DOMANIN\loginID) from the xml. It doesn't read the data in xml using ...
1
vote
2answers
149 views

Changing link target to _blank has no effect

On my masterpage I have added the following script: function replaceLink() { var elems = document.getElementsByTagName("a"); for(i in elems) { var elem = elems[i]; ...
1
vote
1answer
190 views

Create a Document Library with column values programmatically with Javascript

I need to create a Document Library and assign it columns with Javascript. I've been searching around and I found the SP.ListCreationInformation documentation. Here is my code so far: function ...
1
vote
2answers
320 views

jQuery.noConflict() and Sharepoint 2010 WebParts

I've made two webparts for Sharepoin 2010 with jQuery plugins fancybox (slider) and cycle (slider). I need to locate both webparts on one page. But it doesn't work. I tried to use jQuery.noConflict() ...
0
votes
0answers
10 views

When we need to use the ECMA Script object model and when server object model.

When we need to use the ECMA Script object model and when server object model.
4
votes
2answers
496 views

Object #<Object> has no method 'showModalDialog'

Consider the following code: var options = { title: 'Create a new Post' autoSize: true, url: url } SP.UI.ModalDialog.showModalDialog(options); The code is executed from a ECB custom ...
0
votes
0answers
66 views

Access the infopath form data using client side object model

I am using client side object model in SP2013. Now I am stuck in a scenario where I need to access infopath form data. I have a lot R & D but not got anything yet.
1
vote
1answer
244 views

column not found when creating list item with Javascript

I am making a SharePoint app with javascript. I am trying to add a list item to a list I have defined in visual studio. I have done this just by adding a list in the solution explorer, and I made ...
0
votes
1answer
327 views

Adding a custom delete button to a custom list form in SharePoint 2007

On a customized dispform.aspx page for document library, I'd like to add a delete button. I'm trying this code from SharePoint Designer, but getting error in sharePoint designer 2007 A string ...
2
votes
1answer
136 views

What is the id of the close button on a modal dialog?

I have a modal dialog and I want to change some of its properties through javascript. I have found the jquery code jQuery("a[id^='DlgClose']") but when I try to use the javascript ...
0
votes
0answers
37 views

display library items in content editor

I have a content editor webpart. There is a table and I would like to display the items of a spezial library in line 2, column 4. I have no idea how to realize this... maybe with javascript?
0
votes
1answer
656 views

Why, on occasion, does executeQueryAsync() fail to execute success OR failure method?

My intent is to dynamically create a grouping of EditControlBlock (List Item Menu) custom actions for two different list view pages. Upon loading the Active page, all custom actions are destroyed, ...
0
votes
1answer
103 views

How to call ExecuteOrDelayUntilScriptLoaded(MainFunction, “sp.js”); in button Click event of javascript?

Can i able to call the ExecuteOrDelayUntilScriptLoaded(MainFunction, "sp.js"); in the button click event of javascript or jquery Is it Possible? Thanks
0
votes
1answer
5k views

How to reterive list item values using CAML query?

I have one Date and time column and text colum. I need to retrieve list item value based on this both column using CAML query.. For ex: Columname---> Date value for date would be-6/1/2013 and ...
1
vote
1answer
86 views

Client Side Error Reporting and Instrumentation in SharePoint 2010/2013

I do a large amount of client side development using SharePoint as the back end. In most cases I rely heavily on the REST API and JSOM. I tend not to use the SharePoint masterpages and deploy my ...
1
vote
1answer
551 views

SP2010 JSOM: updating with CAML where clause

So I learned and have used the following to update a list item by ID using Javascript Client Object Model: function updateItem(passedID) { var ctx = new SP.ClientContext.get_current(); var myList = ...
0
votes
0answers
75 views

print function is not working fine with the script code

` .styled-button-2 { -webkit-box-shadow: rgba(0, 0, 0, 0.0976562) 0px 1px 0px 0px; background-color: #EEE; border: 1px solid #999; color: #666; font-family: 'Lucida Grande', Tahoma, Verdana, ...
0
votes
1answer
176 views

How to get the list item column values based on the html drop down and display in the alert box using Javascript?

I have a html dropdown list(team name) which contains three values A,B,C I have a sharepoint 2010 List A which contains Team name and Email. List A Teamname Email A A@test.com B ...
0
votes
0answers
80 views

Mimicking Sharepoint Global Navigation popout

I need some help creating a custom global navigation bread crumb control. What i'm trying to do is mimic the behavior of Sharepoint2010s After modifying the css to get the popout to always display, ...
0
votes
2answers
336 views

How do I delete potentially many items from more than one list using JavaScript?

I'm trying to use a script to remove multiple list items from multiple lists. I'm using Javascript because I don't have access to Visual Studio. The idea is there's a Parent List item in a ...
4
votes
2answers
1k views

SP2010 REST API from Javascript: how to set multiple fields to filter on in the URL

weird but i can't figure this out or find a solution anywhere.... I want to filter on two values on a GET in REST URL from javascript. So since this is from ECMA I am just using filtering in the ...
0
votes
0answers
193 views

ListView Web Part - Paging Issues

I have a wiki page that has a search box that is connected to a listview webpart. The connection works great, and I get accurate results. Paging is enabled on the listview and set to 100 results. ...
1
vote
0answers
192 views

How to get the distinct values from sharepoint list using GetListItem and bind to dropdown?

I am Passing the XML for getting List item and binding to dropdown. Here i have shown the code.. <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" ...
1
vote
1answer
108 views

How to pass arguments to SPServices function request?

In SPServices library, I make a search request using: $().SPServices({ operation: "Query", queryXml: queryText, completefunc: searchComplete }); function searchComplete(xdata, status) { ...
3
votes
1answer
106 views

SP2010 possible to create a text file in document library and fill with data from list using JSOM JavaScript/jquery

Is it possible to create a new item in a library and default that to a txt file or XML and using JavaScript or jquery insert data from a list into that file? For example from a page click a button ...
0
votes
0answers
256 views

Read Only or Edit prompt (call DispEx) in Callback

I have created a ribbon button for Document Library. When user clicks the button, some changes will be applied to the document. Once the changes are done, a method will be callback-ed and try to open ...
2
votes
2answers
2k views

Why is this CAML Query returning all items regardless of the <Where> element definition?

I'm trying to retrieve a list of items where a specific field matches a specific value. There is likely going to be multiple items returned when the query is successful. Here's what my CAML query ...
1
vote
1answer
96 views

Search problem - JavaScript SubmitSearchRedirect - WSS 3.0

I am trying to search using the default search control from sharepoint. <asp:ContentPlaceHolder id="PlaceHolderSearchArea" runat="server"> <SharePoint:DelegateControl runat="server" ...
0
votes
1answer
51 views

Reference for ECMAJavascript Library gets?

Is there a method reference for all the gets/sets in the. ECMAScript JavaScript library for sharepoint 2010. I know the obvious answer is MSDN but I have trouble finding anything there. For example I ...
3
votes
1answer
2k views

SP2010 Javascript REST API: updating list item using MERGE and POST

I am trying to use REST API approach in javascript to update a sharepoint list item where I have an id. So I use GET and POST to create records, but per MSDN article it looks like the way to do this ...
0
votes
0answers
351 views

ecmascript check if item exists in lists

I have to check whether _spuserid exists in 10 lists of same structure and columns. var arrayOfLists=["list1","list2","list3",.......,"list10"]; for(var i=0;i<arrayOfLists.length;i++) { var ...
0
votes
0answers
34 views

Put a break in javascript function

Hi I have 10 sharepoint lists.structure,column name,data type all are same. I need to check whether a particular item is found in any list then do some action using ecmascript. var ...
0
votes
0answers
73 views

SP2007: Upload a file to data view of document library using JavaScript

I'm new to SharePoint 2007 and looking if someone can help me on this. I have a data view that displays basically documents in a library. I was asked to add an "upload file" functionality using ...
0
votes
0answers
125 views

SPServices Search - select first x items using sql type query?

I am using the SPServices library to make search requests in Sharepoint 2010 using this code: queryText = "<QueryPacket xmlns='urn:Microsoft.Search.Query' Revision='1000'>"; queryText += ...
0
votes
1answer
270 views

How to use SPServices search sql query - getting malformed query

I am using the SPServices javascript library to make a search request to sharepoint 2010 search. I am trying this query: queryText = "<QueryPacket xmlns='urn:Microsoft.Search.Query' ...
0
votes
1answer
296 views

set taxonomy field multiple values

I'm creating a sharepoint hosted app which is based on javascript only. I wanted to update a multivalue taxonomy field in a list so I wrote this function which didn't work. there is a very little ...
1
vote
2answers
114 views

How to write a caml query that filters by .pdf or folders?

How can I write a CAML query (for javascript ecma) that filters by only pdf documents or folders in sharepoint 2010? (this is for document libraries) Thanks.
0
votes
1answer
63 views

Web Part Javascript best practice

I have extended the CoreResultsWebPart in order to do some custom processing, but I am now considering breaking out some of the functionality into a new web part. Is it considered bad practice to use ...
0
votes
1answer
69 views

Creating directory structure from custom ribbon action

Environment: 2013, VS2012 I'm trying to develop a custom ribbon button for a document library that creates a folder (ie: a new project) and populates it with a hierarchy of sub-folders. I have some ...
1
vote
0answers
75 views

JavaScript function in URL field value

Is it possible to set the value for the URL field so that when clicked it runs a JavaScript function? I have created a field which stores links to files in SharePoint, but when clicked, the file is ...
0
votes
2answers
375 views

Lists.asmx and List Item Attachments

How would the lists.asmx service be used to add an attachment to a list item with JavaScript File API? I cannot find an example of anything other than copy.asmx for adding documents. Update: Here ...
0
votes
0answers
88 views

Getting error when doing a search with SPServices

I want to run searches with jquery and spservices library. This is what I have so far: <script type="text/javascript" src="/js/jquery/jquery-1.10.1.min.js"></script> <!-- <script ...
2
votes
1answer
304 views

Create Taxonomy sub-term using CSOM and javascript

in sharepoint managed metadata I found very little documentation on managing terms using javascript CSOM. I could create a taxonomy term directly under the term set but I want to create a term under ...
3
votes
1answer
1k views

SP2010 JSOM Client Object Model: How to get all documents in libraries including all folders recursively

I have seen a lot of examples and questions about this out there but nothing I have found has helped me accomplish this. I need to be able to grab all the names of the documents within a given ...
0
votes
2answers
967 views

Why does JSLink code associated with a site column fail to render on first load of document library view, but renders successfully on page refresh?

Bit stumped on this one, wonder if anyone can help? I've created some JavaScript which is stored in the Style Library and referenced by the JSLink property of a site column. When I navigate to a ...
1
vote
0answers
182 views

ListData.svc: How to upload attachment?

How does one upload an attachment to a list item using JavaScript/HTL5 file upload API and the ListData.svc API? I know I can do this using managed CSOM but I want to understand the SP 2010 REST API ...
2
votes
2answers
229 views

SP2010: Get all library names within a site using javascript client object model?

How do I get the names of all libraries within a given site using jquery/javascript? the only way i know of is using getByTitle('listtitle'), but I would like all names of libraries (hopefully there ...
1
vote
1answer
125 views

SPAPI_Core.js access denied

I have old web page which I am trying to set up on new sharepoint site, is uses SPAPI_Core.js, but I am getting access denied error to this js library. Can someone help?
0
votes
1answer
82 views

Dependencies in the jscript file

Lets say, I have custom-dialog.js that depends on custom-notifier.js and this one depends on sp.js. What's the best practises to write dependencies inside mine custom .js files?
0
votes
1answer
227 views

sharepoint 2010 rest api javascript error: 5009 sys is undefined

I am running into something that I haven't really seen before, and I have been using this approach quite a bit lately for a variety of pages. SharePoint 2010 javascript using REST API to grab data: ...