I was looking into the Office 365 apps for our projects, where we have to get the user properties for the logged in user from the Azure AD. Just putting together some code and the article referenced, so that it will be helpful. Articles: Registering an application in the Azure AD Azure AD Graph api
Objective: implement custom sort functionality for list items make order number (rank) visible on the list First, let’s create custom action for reordering items and make hidden field Order visible and sortable on default view with PowerShell. [void] [System.reflection.Assembly]::LoadWithPartialName(“Microsoft.SharePoint”) | out-null # Add “Change item Order” button at target List $siteUrl = “yourSiteCollectionUrl”; $listTitle =
Whether you are developing for Office 365, SharePoint 2013, ASP .NET, or another web option, these days you are going to need some “go-to” JavaScript libraries to enhance your solutions. No matter what project I am on, over the past few years these are the JavaScript libraries I have learned to use and integrate with
Today I was asked how to retrieve all of the SharePoint Groups of the currently logged-in user to sharepoint. To achieve this, first you need to recover the authority connected to sharepoint with the function GetCurrentUser and then read the “ID” property. Once you have this, you can then use the GetGroupsOfUser (userId) that takes as input
After struggling for some time and a whole lot of googling I was able to make this work as magic (that is with JavaScript/jQuery). Here’s what we’ll need to do: Create a Display Template Add some JavaScript/jQuery Simple right? Yes, after figuring out how to do it it is… Display Template For the display template
A sample JS to clear the taxonomy field value using the JS CSOM. example: var context = SP.ClientContext.get_current(); var list = context.get_web().get_lists().getByTitle(“list title”); var listItem = list.getItemById(58); var field = list.get_fields().getByInternalNameOrTitle(“taxonomyfieldname”); var taxField = context.castTo(field, SP.Taxonomy.TaxonomyField); listItem.parseAndSetFieldValue(“taxonomyfieldname”, “”); listItem.parseAndSetFieldValue(“taxonomyfieldnameTaxHTField”, “”); listItem.update(); context.load(listItem); context.executeQueryAsync(function () {},function(){}); The above code clears the Taxonomy field value using the
This post illustrates how to create a new SharePoint Site based on custom template using Web API. Required parameters: contextUrl, url, title, Webtemplate Where: contextUrl = https://server.sharepoint.com url = mysite Webtemplate = STS#0 var requestUri = contextUrl + ‘/_api/web/webs/add’; return $.ajax({ url: requestUri, type: “POST”, data: “{ ‘parameters’: { ‘__metadata’: { ‘type’:
In this example I will modify jQuery to work correctly with Scripts on Demand, Minimal Download Service, Client Side Rendering, and to be compliant with SharePoint best practices. Over Demanding Scripts Scripts on demand requires some preparation, before files can properly be registered. The requirements are: Code should not be in the Global Namespace Code
Customers keep asking for dynamic content to be displayed as ’tiles’. The Promoted Links View is only available for static lists, and the Tile Display Template for CSWP is missing. So; I created it! Normally, I would attack this problem with special styling on SharePoint, however, for the first time I’m using SharePoint styling on
Issue: We have several user reporting the issue that they suddenly started getting error when they try to open the SharePoint sites Error: You may be trying to access this site from a secured browser on the server. Please enable scripts and reload this page. Troubleshooting: We did check the basic settings in IE of the users
Page [tcb_pagination_current_page] of [tcb_pagination_total_pages]