SharePoint 2013 Online Version Settings

Introduction

In this article, we will see how to create/ configure the version and advanced settings in SharePoint Online Ooffice 365.

After Microsoft launched One Drive for SharePoint Online, the most common workday challenge is organizing documents and sites. Some ways are given below with which you can organize documents and sites in One Drive for Business.

Office 365 provides a variety of ways to find the documents, which you need quickly.

Office 365 introduced many features in the document library to maintain the documents and store the documents.

If you want to get the documents, which are based on the name, in the left side search box; enter the document name and it will return the documents, which are based on the queryText.

SharePoint

It will return based on the conditions given below.

  • Documents in your OneDrive for Business.
  • Documents that someone has shared with you.
  • Documents that are stored on a site, which you follow.

We can see the version settings and advanced version settings about document library.

Click the library settings icon in your SharePoint site.

SharePoint

Click Version Settings link.

SharePoint

In the content approval section, specify whether new items or changes to the existing items should remain in a draft state, until they have been approved.

Specify whether a version is created each time when you edit a file in this document library.

Create a version each time, when you edit a file in this document library.

  • No versioning
  • Create major versions

Example

1, 2, 3, 4

  • Create major and minor (draft) versions.

Example

1.0, 1.1, 1.2, 2.0

We can specify Drafts are minor versions or the items, which have not been approved. Specify which users should be able to view the drafts in this document library.
SharePoint

We can give the restrictions to the library.

  • Any user, who can read the items
  • Only users who can edit the items
  • Only users who can approve items (and the author of the item).
Specify whether the users must check out documents prior to making changes in this document library.

SharePoint

Click OK button to save the version settings of SharePoint document library.

Programmatically change the version settings in SharePoint, using CSOM.

 Code

  • Open your Visual Studio.
  • Copy the code given below and paste in your Visual Studio.
  • Run it.
    1. using Microsoft.SharePoint.Client;  
    2. using System;  
    3. using System.Linq;  
    4. using System.Security;  
    5.   
    6. namespace GowthamTutorial  
    7. {  
    8.     class Program  
    9.     {  
    10.         static void Main(string[] args)  
    11.         {  
    12.             
    13. ClientContext context = new ClientContext(''https://gowthamr.sharepoint.com");      
    14.  Web web = context.Web;      
    15. string  pwd =''XXXXX ;     
    16. string  userName='XXXXXXX';  
    17.    
    18.  context.Credentials = new SharePointOnlineCredentials(userName, pwd);      
    19.  context.Load(web);      
    20.  context.ExecuteQuery();      
    21.  List list = context.Web.Lists.GetByTitle(''Documents');      
    22.  context.Load(list, l => l.EnableVersioning, l => l.EnableMinorVersions);      
    23.  context.ExecuteQuery();      
    24.  list.EnableVersioning = true;    
    25.  list.Update();      
    26.  context.ExecuteQuery();      
    27.   
    28.             }   
    29.         }  
    30. }  

Example

SharePoint

Click version history menu settings.

SharePoint
SharePoint
Click View icon and it will redirect to here.

SharePoint
Now, publish this document.

Conclusion

When versioning is enabled in the site lists and libraries, you can track and manage the information as it evolves. This will help you to find enabled version settings in SharePoint Online.

Was my article helpful?

If so, please let me know at the bottom of this page. If not, let me know what was confusing or missing and I’ll use your feedback to double-check the facts, add info and update this article.

Up Next
    Ebook Download
    View all
    Learn
    View all