Opening a web part page in maintenance mode

SharePoint doesn't work as intended

Can’t access a web part page because of a broken web part? Yeah, that’s a classic issue – and it’s nicely ported into Modern world, too! In these cases, web part page maintenance mode comes in handy!

There’s a query parameter available for accessing it. For whatever reasons, it’s different for Classic and Modern mode, though. Why make things easy if you can make them dificult, right? 🙂  Continue reading

How to show a Classic SharePoint page in dialog mode (without SharePoint’s full-blown chrome)

Let me explain SharePoint

Classic SharePoint actually has a very handy piece of functionality, using which you can hide most of the SharePoint chrome (like header and navigation), and hence make the page a lot more sleek. This is especially useful for showing the contents in a dialog window – which SharePoint also supports natively through JavaScript! This post describes how.

How to show any (classic) SharePoint page in dialog mode?

Pretty easy – it’s handled via a url parameter!  Continue reading

How to get rid of Foxit Drive in Foxit Reader

Not sure if a bug or a feature

If you’re like me, you’re not using Adobe Reader, but rather switched to Foxit Reader years ago, and never looked back. Foxit has a great PDF printer, it’s a great reader, but not perfect. The default save location is “Foxit Drive”, and it pops up any time you try to save your document, and at least for me interrupts my workflow. This post describes how to get rid of it, and make Foxit Reader even better!

Description of the issue

Okay, so Foxit Reader is pretty great, but they’ve got their difficulties, too. Being freeware, they kind of need to get revenue from somewhere outside the reader itself – and nowadays, that would be their Premium software, but especially their Online offering, part of which the cloud storage for PDFs is. Continue reading

How to output console or PowerShell transcript to a file in Windows

Console output copypaste

Every now and then, you run into a situation, where you’ll need to somehow output the transcript of a console app run. I’m actually going to argue it happens a lot more often than one would think – in my case, any time a customer requires a webjob or a function, that one would normally deploy to Azure, being ran on the servers of the customer.

Problem

Something breaks or the app crashes, and the error is logged to event log… But just the error, not the whole transcript. You’d like to get it all, to figure out what’s actually going on, but event log is not the way to go.

What to do?

Solution: redirect the output directly to a file

Continue reading

How to solve “Unified Groups aren’t supported.” -error

Unified Groups aren't supported.

When trying to use some functionality, that relies on Unified Groups, you’re getting errors in the console, similar to this: “Unified Groups aren’t supported.” In truth, this most likely means, that Unified Groups (that’s the internal/technical name for Office 365 Groups) is not enabled for this particular user. That breaks a bunch of different features for them, since the Graph API for Groups of course won’t work. This post describes one way to fix this issue!

How to solve this?

Continue reading

Using “DetectedLanguage” to return only localized results from SharePoint Search index

How to SharePoint?

Localization and targeting of content in multilingual SharePoint installations is always an issue. SharePoint offers a multitude of ways profile content based on user language (or other properties), but none of the solutions are fool proof. This post describes how to fetch only localized results from SharePoint Search index, which solves at least some of the issues.

Description 

SharePoint Search index can be used in quite a few different ways. Probably the most typical way is by searching on SharePoint, or using webparts like Content Search or Content Results. However, one can also build custom functionality, custom client-side liftups, webjobs, single-page applications, mobile applications and a ton of other things that fetch data from SharePoint search index. However, on multilingual tenants, results are, by default, not localized at all. That means, that typically everyone will get the highest-ranking results back, despite them being in the wrong language. And that’s one of the many, many ways to annoy your users!

Continue reading

4 ways to fix error AADSTS65001 (The user or administrator has not consented to use the application)

Azure AD Login error

Fixing issues with Azure AD authentication for Enterprise applications can be tricky. This article contains multiple different fixes to an issue, where granting admin consent has somehow failed. Not all of the different solutions will work for all situations, though! That’s why I included a couple of different options to try… 🙂

Why do you even get issues with Admin Consent (like AADSTS65001)?

Imagine this: You’re trying to add or use an app, but the requires such permissions from your tenant, that only an administrator can grant.

Typically to add this kind of an app, you’ll have to be a global administrator. If it’s an enterprise application, it could also be in an invalid state after someone tried adding the app without sufficient permissions.

Our investigation was focused on a mobile app, that’s deployed as an enterprise app. Most of the things should apply for web-based apps or console programs or whatever else you’re deploying, too.

The whole error might look something like this: Continue reading

How to use the Azure AD associated with your SharePoint Online

Azure Active Directory (Azure AD)

With the usual configuration of Office 365 and Azure, there might be multiple Azure AD (AAD) instances associated with your subscription. When creating registrations to whatever SharePoint-related apps that you might be using, if you create the registration to the wrong Azure AD, it can’t access the data in your SharePoint. Or at least without further configurations, it probably won’t get any data from your Office Graph API or whatever else you might want to use. 

How to find the instance of Azure AD associated with your SharePoint Online

It’s simple, luckily!  Continue reading

New version of Microsoft.IdentityModel.Clients.ActiveDirectory (ADAL.NET) is out – good time to update!

Mock Function call to force loading an assembly - how elegant!

 There’s now a new version of the assembly Microsoft.IdentityModel.Clients.ActiveDirectory available – plenty of reasons to update right away! Let me offer you one hot take on the matter.

Why bother updating?

In an earlier post I described an issue I had with Microsoft.IdentityModel.Clients.ActiveDirectory.Platform not getting copied during the build in a referencing project. In 3.17.0, which the developers published this month, they fixed the issue! The new package actually contains separate DLLs for different platforms.

In essence this means, that from C#/.NET -developer’s standing point, the team has assimilated the Microsoft.IdentityModel.Clients.ActiveDirectory.Platform assembly, among other platform DLLs, into Microsoft.IdentityModel.Clients.ActiveDirectory package itself. Hence, you’ll need no more funky hacks to ensure, that Visual Studio will end up copying the DLLs during the build! 🙂

What’s new with Microsoft.IdentityModel.Clients.ActiveDirectory 3.17?

Continue reading

Using SharePoint Search Query Tool

SharePoint Search Query Tool

If you’re working on SharePoint deployments, and aren’t familiar with SharePoint Search Query Tool, you’re probably doing something wrong. Or you’ve gotten a really troublefree tenant and simple requirements.. 🙂 At least for technical issues, it’s the #1 tool for debugging what’s in the index and what isn’t. This blog post describes how to use it to investigate SharePoint Online Search index issues.

This blog post is about using SharePoint Search Query Tool to investigate search index issues in SharePoint Online. First of all, you can get the tool from here: https://sp2013searchtool.codeplex.com/.

Continue reading