I’ve previously posted PowerShell scripts that allow you to extract Content Types or Fields from a SharePoint site. But last week a commenter by the named Jeff posed a valid question. What if I want to extract all Content Types in a SharePoint site, and show the associated Fields for each of them?
Sometimes you need to change the properties of a Web Part without browsing to the page itself and set it. There could be numerous reasons as to why you would want or need to do this. A while back I created a really simple redirect web part for one of my clients. It had two custom properties, EnableRedirect and Url. If EnableRedirect was true, it would redirect the user to the specified Url. Obviously, if you want to change either of these properties while the EnableRedirect is true, that's going to be a problem.
Fast forward and the redirect web parts need to be changed and/or disabled. Obviously we can't navigate to the page and just change it, because the page will redirect you. But it can be done relatively easy using PowerShell.
So you just found the wicked awesome list of content types and life is good, but you kinda wish you could get a hold of all those content types and column fields that you made yourself. No worries, Powershell is your trusted friend who's always ready to help.
Below are two very basic Powershell scripts. They both connect to a specified site collection, and one exports Content Types while the other exports Column Fields.
I do a lot of CSS styling with my current project, and with that comes a lot of trial and error. I make image files, upload them, see how they look, delete them, upload new ones, take a look again, and so on. Depending on what stage I am in designing the page, I sometimes just stick the images in the Style Library and load them from there inside my CSS.
Luckily there's a "Upload multiple files" option in Sharepoint, but unfortunately there's isn't a quick way of checking in multiple files of a single directory. Well, there sort of is... But I just like Powershell better. Anyway, for the longest time I was clicking on each file individually and checking them in one by one. I figured there has got to be an easier way! Turns out the answer is Powershell.