Create Tab in Office 365 SharePoint Lists

This short article shows you how to create tab look in SharePoint Custom Lists

When I went to I saw the tab I want but how am I going to put this in my Office 365 SharePoint.

  1. Create a SharePoint Custom List
  2. Open SharePoint Designer 2013 and point to the SharePoint site.
  3. Choose Lists and Libraries.












4. Choose a List, in my example is Tabblist.









  1. Click New in Forms.
  2. Name the form, for example, NewFormCust.aspx. Check the Set as default form for the selcted type.



7. Click on the new form, NewFormCust.aspx, to edit.

8. Click on the Advanced Mode.



9. Under the line

<asp:Content ContentPlaceHolderId=”PlaceHolderMain” runat=”server”>

add the JavaScript

The JavaScript as below.

function openCity(evt, cityName) {
// Declare all variables
    var i, tabcontent, tablinks;

// Get all elements with class=”tabcontent” and hide them
    tabcontent = document.getElementsByClassName(“tabcontent”);
for (i = 0; i < tabcontent.length; i++) {
tabcontent[i].style.display = “none”;

// Get all elements with class=”tablinks” and remove the class “active”
    tablinks = document.getElementsByClassName(“tablinks”);
for (i = 0; i < tablinks.length; i++) {
tablinks[i].className = tablinks[i].className.replace(” active”, “”);

// Show the current tab, and add an “active” class to the link that opened the tab
    document.getElementById(cityName).style.display = “block”;
evt.currentTarget.className += ” active”;
  1. Under the line

<SharePoint:CssRegistration Name=”forms.css” runat=”server”/>

Add the css

<SharePoint:CssRegistration Name=”server”/>

The css code as below.

.tabcontent {
    -webkit-animation: fadeEffect 1s;
    animation: fadeEffect 1s; /* Fading effect takes 1 second */

@-webkit-keyframes fadeEffect {
    from {opacity: 0;}
    to {opacity: 1;}

@keyframes fadeEffect {
    from {opacity: 0;}
    to {opacity: 1;}

11. Look for



            <td width=”190px” valign=”top” class=”ms-formlabel”>

            <H3 class=”ms-standardheader”>

            <nobr>Title<span class=”ms-formvalidation”> *</span></nobr>



add the follow code before that.



    <ul class=”tab”>

        <li><a href=”#” class=”tablinks” onclick=”openCity(event, ‘London’)”>London</a></li>

        <li><a href=”#” class=”tablinks” onclick=”openCity(event, ‘Paris’)”>Paris</a></li>

        <li><a href=”#” class=”tablinks” onclick=”openCity(event, ‘Tokyo’)”>Tokyo</a></li>


    <div id=”London” class=”tabcontent”>


        <p>London is the capital city of England.</p>


    <div id=”Paris” class=”tabcontent”>


        <p>Paris is the capital of France.</p>


    <div id=”Tokyo” class=”tabcontent”>


        <p>Tokyo is the capital of Japan.</p>



When you create a new item now then you should see.

Create tab in Office 365 SharePoint List












Share this on...

Rate this Post: