kwizcom banner advertisement

Update Theme for All Site collections, Sub-Sites in SharePoint

8:48 PM    , , , , ,
Requirement: Update new theme in for All Site collections, Sub-Sites in SharePoint C# code to do that: using System; using System.Collections.Generic; using System.Text; using Microsoft.SharePoint; using Microsoft.SharePoint.Administration; using System.IO; namespace Theme_Update { class Theme_Update { static void Main(string[] args) { string site; try { if (args.Length == 0) { Console.WriteLine("Enter the Web Application URL:"); site = Console.ReadLine(); } else { site = args[0]; } SPSite tmpRoot = new SPSite(site); SPSiteCollection tmpRootColl = tmpRoot.WebApplication.Sites; //Enumerate through each site foreach (SPSite tmpSite in tmpRootColl) { //Enumerate
Update Theme for All Site collections, Sub-Sites in SharePoint Update Theme for All Site collections, Sub-Sites in SharePoint Reviewed by Salaudeen Rajack on 8:48 PM Rating: 5

Archive (Backup and Delete) IIS Logs in SharePoint

7:38 PM    , , , ,
IIS logs are the requests from clients, and written into text-based log files. It captures every web page/image/script requests. By default, IIS logs stored in C:\ of WFE servers. If SharePoint is being accessed a lot, It may cause disk space problem for your OS drive so quickly. So we can change this log path. Here is how: Go into IIS Manager for each WFE. (Start > run > Inetmgr) select the server name in the Connections panel on the left. In the Features view shown in the middle panel, select Logging. For the log file, change the directory to a more suitable drive and folder. For example, I’ve changed the path for the log files to D:\Logs\IIS. How about backing up them Monthly and deleting old logs? Its a good idea to backup and clean IIS Logs every Month. These Logs are highly compressible up to 500%!!! (Meaning 500 MB file to 5MB file). Steps: 1. Download and import the PowerShell community Extension (for write-zip cmd-let) 2. Write the script to Zip and Delete
Archive (Backup and Delete) IIS Logs in SharePoint Archive (Backup and Delete) IIS Logs in SharePoint Reviewed by Salaudeen Rajack on 7:38 PM Rating: 5
Powered by Blogger.