Import-SPWeb: Failed to read package file
A few days ago I wanted to restore a SharePoint list (including data) on a development server via the Import-SPWeb cmdlet based on a backup created by the Export-SPWeb cmdlet in the productive farm:...
View ArticleFind Your Scripts in SharePoint within Seconds – the Effective, but...
The SharePoint environment I’m working on contains hundreds of webs. I create test sites for various tasks (like prototyping JSLink-based solutions) including the necessary lists, and store the .js and...
View ArticleBulk Deletion of Events from a SharePoint Calendar
Assume you have a SharePoint Calendar with thousands of events, including recurring events, and recurring event exceptions. These ones are the result of aggregating events from several years, most of...
View ArticleHow to Export a SharePoint List View to Excel Automatically Using PowerShell
Note: This post is actually only a minor modification of the post I wrote recently about the URL of the Edit View page. We can easily export the content of a SharePoint List View via the UI, simply by...
View ArticleApproving all pending documents (and folders) of a specified library using...
A few years ago I already wrote about how to approve all pending document in a document library via PowerShell. That time I achieved that using the server side object model of SharePoint. Recently we...
View ArticleHow to query your working hours from Windows Event Log via PowerShell
At my company we have a kind of time reporting application. If I book the activities the same day, there is no problem. But after a week, it is not always straightforward to remember what I exactly did...
View ArticleEditing the PWS Site Address does not work if the URL is very long
As part of our daily jobs, we should rename projects on our Project Server occasionally. For this kind of change, we have already a “human workflow” or a check list: tasks, we should perform one after...
View ArticleDisplaying Filtered or Sorted SharePoint Web Properties from PowerShell
Specific SharePoint applications and services as well as tools, like SharePoint Designer tend to store their own settings in the property bag of web sites. Especially root webs of site collection have...
View ArticleHow to detect if your DbConext is already disposed
A little background (or let’s say context) to the story. Recently I had to create a tool (of course it was SharePoint-related) that needs to import a quite large number of entries into a SQL database...
View ArticleCopy an XsltListViewWebPart from another SharePoint Site via PowerShell
It’s a common request, that the user would like to display a SharePoint List / Document library from another site. Unfortunately, that is not so easy. Users see only the lists exist on the current site...
View ArticlePaging through the Entities returned by the ProjectData OData Interface of...
About a year ago I wrote about how you can use PowerShell and Project Server REST interfaces (ProjectServer and ProjectData) to generate reports. However, at the end of last year we had a problem with...
View ArticleCopy an XsltListViewWebPart from another SharePoint Site via PowerShell – The...
In my recent post I’ve illustrated, how to display SharePoint lists from other sites via PowerShell. As I told you, that solution does work only if you have direct access to the SharePoint server....
View ArticleQuerying SharePoint Search Preferences from Code
Recently a user complained, that he is not able to open office documents from the SharePoint portal of the company when working at home. He attached a screenshot of the error message in the browser to...
View ArticleChanging SharePoint Search Preferences from Code
In my recent post I’ve illustrated with C# and PowerShell examples, how to read search preferences info from code, both for the current user as well as for other users. In this post we will see, how to...
View ArticleHow to check if a specific file exists in a folder structure of a SharePoint...
Recently we had to create a utility function that makes it us possible to check if a file having a specific name exists anywhere within a folder structure of a SharePoint document library. As long as...
View ArticleQuerying SharePoint list items including their attachment in a single request...
Assume there is a SharePoint list including a few hundreds of items, each item might have a few attachments, but there might be items without attachments as well. We need to display only some of the...
View ArticleCreating statistics about web part usage from the SharePoint content database
Recently I had to create some statistics about SharePoint web site customizations, like on which pages are there Script Editor Web Parts, or Content Editor Web Parts, etc. I knew I could and probably...
View ArticleFaking feature activation properties
Assume you have a feature receiver in your SharePoint project. You would like to perform multiple actions if the feature is activated, so you organize your code according to the actions into static...
View ArticleThe sub-webs delivered to you are dirty
Recently I had to perform a simple administrative task: a SharePoint website had several sub-webs, each of them having unique permissions. Our goal was to reset the permissions to be inherited from the...
View ArticleHttpRequest.Url contains always the full URL of the current request, doesn’t it?
Recently we had to create a Wellcome menu extension in SharePoint to make a custom application page available from all of the web site context, like standard lists and pages as well as standard and...
View Article