Posts

Showing posts from 2017

Sync SharePoint online document library to your system

Image
How to Sync SharePoint online document library to your system Step 1: Go to the library you want to sync with your PC and click on Sync button. Step 2: Now Click on Open Microsoft OneDrive. Step 3:  Click on Start Sync botton to sync your library. Step 4:  Here is your synced library. 

Retrieve Data from SharePoint List using REST api

Retrieve Data from SharePoint List using REST api jQuery <script type="text/javascript" src="https://ajax.aspnetcdn.com/ajax/jQuery/jquery-1.12.4.min.js"></script>  <script type="text/javascript"> var listName = "ListB";     // This code runs when the DOM is ready and creates a context object which is needed to use the SharePoint object model     $(document).ready(function () {         GetEmployeeDetails();     });     function GetEmployeeDetails() {         $.ajax({             url: _spPageContextInfo.siteAbsoluteUrl + "/_api/web/lists/GetByTitle('" + listName + "')/items?$Select=Title,EmployeeName,Salary,Dept/Title,Dept/Code,Dept/pqol&$expand=Dept",             type: "GET",             headers: { "Accept": "application/json;odata=verbose" }, // return data format             success: function (data) {                 //console.log(data.d.results);

Insert data to SharePoint List using JSOM

Insert data to SharePoint List using JSOM   <script type="text/javascript" src="https://ajax.googleapis.com/ajax/libs/jquery/1.12.4/jquery.min.js"></script>  <script type="text/javascript"> $(document).ready(function () {              $("#btnSubmit").click(function () {             createItemsToList();         });     });     function createItemsToList() {               //List Name         var listTitle = "EmployeeList";         //Get the current client context            context = SP.ClientContext.get_current();         var List = context.get_web().get_lists().getByTitle(listTitle);         //Create a new record         var listItemCreationInformation = new SP.ListItemCreationInformation();         var listItem = List.addItem(listItemCreationInformation);         //Set the values         listItem.set_item('Title', txtEmpName.val());         listItem.set_item('Email', txtEmail.v

Enable Rating to SharePoint Lists or Libraries

Image
How to enable Rating to a list or library in SharePoint Go to list settings à Under general settings click Rating settings à Enable rating settings.

Modal pop ups in SharePoint

Image
Modal pop ups in SharePoint There may be requirement to implement modal pop ups in SharePoint, to use them we need to use below code : <script type="text/javascript" src="https://ajax.aspnetcdn.com/ajax/jQuery/jquery-1.12.4.min.js"></script> <script type="text/javascript">     $(document).ready(function() {         $("#btnShowPopup").click(function(){             ModalPopUp();         });     }); function ModalPopUp() {           var options = {         url: 'http://Server:Port/sites/Test/Lists/ListName/AllItems.aspx' ,         title: 'Title',         allowMaximize: false,         showClose: true,         width: 500,         height: 350     };           SP.SOD.execute('sp.ui.dialog.js', 'SP.UI.ModalDialog.showModalDialog', options);     return false; } </script> <input type="button" id="btnShowPopup" value="Show Modal up"/>

Embed Weather Forecast in SharePoint

Image
Embed Weather Forecast in SharePoint Step 1: Create a Page, Edit it and add Script Editor Web Part to it. Step 2: Paste the below Code. <iframe id="forecast_embed" frameborder="0" height="245" width="800" src="//forecast.io/embed/#lat=28.704059&lon=77.102490&name=New Delhi&color=#00aaff&font=Georgia&units=ca"></iframe> Note : lat( Latitude)  and lon(Longitude) are different for each location. Please specify latitude and longitude of your desired location.   Click Here if it does not work with SharePoint Online

Enable Comments on Site Pages in Office 365

Image
Enable Comments on Site Pages in Office 365 Step 1:Login to your Office 365 admin center page with administrator account, then choose Admin. Step 2:Go to SharePoint Admin Center. Step 3:Select "Enable comments on Site Pages".

Enable Custom Script in Office 365

Image
Enable Custom Script in Office 365 Step 1:Login to your Office 365 admin center page with administrator account, then choose Admin. Step 2:Go to SharePoint Admin Center. Step 3:Select Allow users to run custom script on personal sites and self-service created sites.

SP.UI.ModalDialog.showModalDialog() Does Not Work Under SharePoint 2013

Migrating from SharePoint 2010 to SharePoint 2013, I have faced this issue "the calls to showModalDialog failed with message that the method cannot be found." SharePoint 2010  Example:  var options = SP.UI.$create_DialogOptions();         options.title = "EMPTY SEARCH BOX";         options.scroll = 0;         options.width = 500;         options.height = 150;         options.url = "/DocumentManagement/EmptySearch.aspx";         options.dialogReturnValueCallback = Function.createDelegate(                        null, portal_modalDialogClosedCallback);         SP.UI.ModalDialog.showModalDialog(options); Follow below steps: 1. Remove the Java Script reference : -  <script src="/_layouts/sp.js" type="text/javascript"></script>  <script src="/_layouts/SP.UI.Dialog.js" type="text/javascript"></script> 2. Add to the url variable "?IsDlg=1"` 3. Replace the command SP.U

Filter data in SharePoint online Document Library

Image
Filter data in SharePoint online Document Library It is very easy to filter data in SharePoint online Document Library, you just need to click on filter icon and choose any filter to filter your data. You can also add a filter of your own choice, for this you need to do following : Go to site settings à Under Site Actions Click on Manage Site Features à Activate Metadata Navigation and Filtering feature. Go to library settings à click on metadata navigation settings Now Add filters of your own choice.

Search api in SharePoint

Image
Search api in SharePoint HTML Code -  <div id="searchDiv">          <b>Search For</b>          <input type="text" id="searchTerm" />          <input type="button" id="btnSearch" value="Search" onclick="searchAppWeb()" />      </div>   <div id="SearchResultsDiv"></div>  Custom Code - <script type="text/javascript" src="https://ajax.googleapis.com/ajax/libs/jquery/1.12.4/jquery.min.js"></script> <script type="text/javascript"> var html;  function searchAppWeb() {        debugger;     //Get the Search Term from textbox      var searchTerm = $("#searchTerm").val();       console.log(searchTerm);     //REST API query URL      var queryUrl = _spPageContextInfo.webAbsoluteUrl + "/_api/search/query?querytext='" + searchTerm + "'";;       console.log(queryU

Embed an RSS feed into your SharePoint site

Image
Steps to add RSS feed into your SharePoint Site Step 1- Obtain the RSS feed URL of the Site you want to get feeds on SharePoint Page by Clicking on below icon. Step 2- Insert RSS Viewer Web Part into the page. Step 3- Configure RSS Viewer Web Part. Step 4- Your Feeds are Ready.

Creating a flow in SharePoint Online

Image
Steps to Create a Flow in SharePoint Online Document Library 1.Go to SharePoint Online document library and click on Create a flow. 2.Click on see more templates to explore available templates.  3.In this case I am choosing the below template.  4.Now create the flow. 5.Now add documents to One drive for business. 6.Now they are also available to SharePoint document library.

Adding a tab in MS Teams Office 365

Image
How to add a tab in MS Teams Step 1 - To open MS Teams,Login to your Office 365 account, go to App Launcher and Choose MS Teams. Step 2 - Click on (+) icon to add a tab. Step 3 - Choose a tab source from available resources, here I am selecting SharePoint as I want to add tab of a SharePoint site’s Document Library. Step 4 - Select the SharePoint Site you want to add. Step 5 - Select the document library you want to add. Step 6 - Name your tab and save it. Step 7 - Here is your SharePoint Document library tab.

How To Enable Anonymous Access in SharePoint

Image
How to Enable Anonymous Access in SharePoint 2010 1.Go to Central Administration, under Application Management, click on the Manage web applications. 2.Make sure you select the site you want to enable anonymous access and click on the Authentication Providers icon. 3.On the Authentication Providers pop-up window click on the Default zone. 4.Under Edit Authentication, check Enable anonymous access and click Save. 5.Going back to Web Application Management click on the Anonymous Policy icon. 6.Under Anonymous Access Restrictions select your Zone and set the Permissions to None – No policy and click Save. 7.Now, web application will allow anonymous access to be set. So, navigate to your top level site collection for the web application. Click the Site Actions > Site Settings. Under Users and Permissions click Site permissions.

SharePoint Migration Tool

Image
SharePoint Migration Tool Announced By Microsoft Microsoft has announced a new migration tool which is free, simple & fast for migrating on-premises content (SharePoint 2013 & File shares) to SharePoint Online or OneDrive in Office 365. The tool can be used by all O365 users, you do not need to be a global administrator to run the tool. Instead you only need read access to the source data and write access on the destination. The tool is able to migrate smaller as well as large data batches and execute them in bulk. Requirements Before you begin, check the requirements prescribed by Microsoft. Recommended requirements for best performance CPU - 64-bit Quad core processor or better RAM - 16 GB Local Storage - Solid state disk: 150 GB free space Network card - 1 Gbps Operating system - Windows Server 2012 R2 or Windows 10 client .NET Framework 4.6.2 Steps to use SharePoint Migration Tool Step 1: Click on Sign in button to proceed next. Ste