Posts

Change Language for current user with JSOM in SharePoint Online

Hi, Here is code which can change language for current user with JSOM : <script type="text/javascript" charset="utf8" src="/sites/BizDev/Style%20Library/SPS/jquery-1.11.3.min.js"></script> <select id='LangSelect' onchange="SetUserLanguage(this.value);"></select> <script type="text/javascript"> function SetUserLanguage(lCode) {     var call = $.ajax({             url: _spPageContextInfo.siteAbsoluteUrl + "/_api/Web/Lists/GetByTitle('Languages')/items?" + "$select=Title,Code,LCode,ID&$top=5000&$filter=Code eq "+lCode,             type: "GET",             dataType: "json",             headers: {                 Accept: "application/json;odata=verb...

Change Site Language with JSOM

Hi, Here is code which can change site language with JSOM : <script type="text/javascript" charset="utf8" src="/Style%20Library/SPS/jquery-1.11.3.min.js"></script> <select id='LangSelect' onchange="SetLanguage();"></select> <script type="text/javascript"> $( document ).ready(function() {     LoadLanguages();     setTimeout(GetUpdatedLangulage, 2000); }); function LoadLanguages() {         var call = $.ajax({             url: _spPageContextInfo.siteAbsoluteUrl + "/_api/Web/Lists/GetByTitle('Languages')/items?" + "$select=Title,Code,ID&$top=5000",             type: "GET",             dataType: "json",             headers: {         ...

Remove App from SharePoint Online with Powershell

Hi, Today I was facing some issues in installed custom app. I was not able to get App Details & also not able to remove the app. I tried alot from interface but I couldn't remove the app. Then I move to Powershell scripts. Here is the powershell script which can remove the app from SharePoint Online. Only prerequisite is you must have SharePoint Online Client Components SDK installed on the system. cls [System.Reflection.Assembly]::LoadWithPartialName("Microsoft.SharePoint.Client") [System.Reflection.Assembly]::LoadWithPartialName("Microsoft.SharePoint.Client.Runtime") Function Get-ClientContext([string]$Url,[string]$UserName,[string]$Password) {     $context = New-Object Microsoft.SharePoint.Client.ClientContext($Url)     $context.Credentials = New-Object Microsoft.SharePoint.Client.SharePointOnlineCredentials($UserName, $Password)     return $context } Function Uninstall-AppInstance([Microsoft.SharePoint.Client.ClientContext]$Context,[...

Tasks List with PNP JS & DataTable in SharePoint

Image
Hi , I have created one example for SharePoint with pnp-js & datatable.  Features which I have covered in this example : Open task display page in new tab. Show Priorities in different colors. Show Percent Completed as Progress Bar Show dates in proper formats. Show Assigned To (Multi-people) Here is the code : You need to add following references : <script src="https://code.jquery.com/jquery-2.2.0.min.js" integrity="sha256-ihAoc6M/JPfrIiIeayPE9xjin4UWjsx2mjW/rtmxLM4=" crossorigin="anonymous"></script> <!-- DataTables CSS --> <link rel="stylesheet" type="text/css" href="https://cdn.datatables.net/1.10.12/css/jquery.dataTables.min.css"> <link rel="stylesheet" type="text/css" href="https://cdn.datatables.net/1.10.12/css/dataTables.bootstrap.min.css"> <link rel="stylesheet" type="text/css" href="https://maxcdn.bootstrap...

Organization Chart with AngularJS

Image
What is Organization Chart? An Organizational Chart shows the internal structure of an organization or company. The employees and positions are represented by boxes or other shapes, sometimes including photos, contact information, email and page links, icons and illustrations. Straight or elbowed lines link the levels together.   This creates a clear visual depiction of the hierarchy and ranks of different people, jobs and departments that make up the organization. Organizational Charts also are known as Organization Charts, Org Charts, Organograms, Organogram Charts (sometimes spelled Organigrams or Organigrammes) and Hierarchy Charts. Don’t be fooled: Despite all the different names, they’re all the same thing. How to create with angularjs & google chart? First you need to create one JS file: OrgChart.JS & copy below text : var app = angular.module( 'OrgChartApp' , []); app.controller( 'OrgChartController' , [ '$scope' , ...