I was trolling through the Sitecore Marketplace the other day and found this cool module for reporting about media library items called Unused Media Manager. I thought this would be a great example of how you can adapt code that would traditionally be written in C# and turn it into a simple script in Powershell.
Here's a quick example of where the new scripts appear within the Sitecore tree.
As you can see, SPE provides a reports folder where you can add scripts that will appear under Reporting Tools > PowerShell Reports.
I selected the Unused media items script which produced the following results:
The above window is produced by using the "Show-ListView" command.
Sunday, April 6, 2014
Wednesday, February 5, 2014
Format Excel Column for Size in GB
Today I was doing some reporting on file sizes and saw that I had columns with data in bytes. When you are looking at the length in gigabytes it can get kinda crazy.
Here's a simple trick:
Format the column with a custom setting and paste this in the format
Original article here
Here's a simple trick:
Format the column with a custom setting and paste this in the format
[<500000]#,##0" B ";[<500000000]#,##0,," MB";#,##0,,," GB"
Original article here
Tuesday, January 21, 2014
Site Down for Maintenance
Here is something that I've been trying to setup as part of our deployment process. The goal is to provide users with a site maintenance page during the deployment. We do not require 100% up-time so this solution should meet our needs. I found additional details here which work pretty nice.
Steps:
- Copy App_Offline.htm.disabled to the website directory and move to App_Offline.htm
- Copy the application’s Web.config to Web.config.backup and move Web.config.disabled to Web.config, replacing the original
- Test that the offline page is rendered
- Deploy file system changes
- Move Web.config.backup to Web.config, replacing the temporary file
- Delete App_Offline.htm
Friday, January 17, 2014
Report Duplicate AD Users By EmployeeID
Note: The employeeID is formatted to 7 characters so that if you had numbers with leading 0s they would still be matched.
Tuesday, November 26, 2013
Hedgehog TDS - Package Version
I wanted to create TDS packages using the version from the project assembly version.
Here's a piece of code that I finally figured out how to accomplish dynamically. Place at the bottom of your .scproj file.
Here's a piece of code that I finally figured out how to accomplish dynamically. Place at the bottom of your .scproj file.
Saturday, November 23, 2013
Friday, October 25, 2013
Subscribe to:
Posts (Atom)


