Printer's misbehaving? Nothing a bit of PowerShell wouldn't fix!

How to change printer paper size using PowerShell?

This article explains (with conveniently copy-pasteable code samples) how you can query your printers using PowerShell and modify properties, such as paper size, for one or more of them. Very useful, if you have multiple printers and multiple computers you use them from, AND if you frequently move between continents, you might face the same, totally typical and widespread issue: Your favorite printer might default to using “Letter” paper size, but you’d really need to get it printed in that sweet, sweet “A4” instead. And…Continue reading How to change printer paper size using PowerShell?

"This is fine" - a fine meme, I mean.

Guide: How to take over and kill a viral AAD tenant?

Rogue Azure Active Directories don’t sound like a huge and widespread problem, but Microsoft’s approach of generating unmanaged, viral AAD tenants whenever they encounter the tiniest reason to do so MUST be driven by some weird internal scorecard where “number of tenants” has a lot of weight, because you do get an Azure AD tenant really easily, and getting rid of one is surprisingly laborious. This guide aims to explain what’s the quickest way to remove one. Background Unmanaged directories can be troublesome because they…Continue reading Guide: How to take over and kill a viral AAD tenant?

PowerShell not loading them DLLs

How to list all of the assemblies loaded in a PowerShell session?

In this article, I’ll do my best to explain how to list all loaded assemblies in a PowerShell session. See PowerShell is great at caching assemblies in the weirdest possible way, so ending up with all kinds of mismatches in loaded DLL versions is pretty typical. Or just being plainly blocked from loading a new one as you already have a cached reference in. I mean, I’ve ran into all kinds of issues even if I only use PowerShell occasionally. Or maybe that’s the reason.…Continue reading How to list all of the assemblies loaded in a PowerShell session?

Of Course I Still #ValoLove You

Long story short: My 6-year career with Valo is now coming to an end. Today was my last day at Valo. This is the longest I’ve ever worked at a company, and I’ve had the time of my life in the many positions I’ve held within Valo / Blue Meteorite. Rarely does a company offer you so many different possibilities and options – and let you grow into the role you’re looking to fill with any support you might need. Anyway – to take a…Continue reading Of Course I Still #ValoLove You

Entity Framework Core logo

Fixing “No database provider has been configured for this DbContext” in Entity Framework Core

I’m using Entity Framework in most projects I’m working on – and for the most part, it’s a pleasure to work with. But as always, there are plenty of chances to run into issues – so obviously, I stumble into all of the rare stuff that IS broken! This one I hadn’t really seen before – “No database provider has been configured for this DbContext”. This time I encountered the issue while setting up a new project and getting started working on the model. EF…Continue reading Fixing “No database provider has been configured for this DbContext” in Entity Framework Core

Azure DevOps - Always Be Shipping!

How to run Robot tests on an Azure DevOps hosted agent?

This short article simply documents how to install the dependencies for running Robot Framework on Azure DevOps’ hosted agents. This simple tip comes in handy when you need to run any UI testing for your project after build, as Robot Framework is a great and widely used tool for that. Let’s quickly take a look at the background of the issue, after which I’m sharing a highly copy-pasteable piece of YAML for your convenience. Well – and mine. Background So I got a question about…Continue reading How to run Robot tests on an Azure DevOps hosted agent?

Azure Functions CLI - such a pretty logo for such an awesome functionality

How to fix “Missing value for AzureWebJobsStorage in local.settings.json” when you’re debugging Azure Functions locally?

Another day, another issue with Azure Functions! For such simple and powerful tool, it sure does produce a lot of topics for blog articles! 😁 So let’s get down to fixing another Azure Functions configuration issue. But wait – what WAS the problem again? Problem When firing up your Azure Functions project locally, this error is what you’re confronted with: “Missing value for AzureWebJobsStorage in local.settings.json. This is required for all triggers other than httptrigger, kafkatrigger. You can run ‘func azure functionapp fetch-app-settings ‘ or…Continue reading How to fix “Missing value for AzureWebJobsStorage in local.settings.json” when you’re debugging Azure Functions locally?

"I know Excel"

How to copy-paste a table from Excel to WordPress without using plug-ins?

So, I tried to paste a table from Excel to WordPress, and I failed. Annoying – but not a big problem. I can just paste it into an existing table and it’ll “sort itself out”, right? Well, no. Exporting the Excel sheet as a html page and copy-pasting the table from there didn’t work either. Actually, copy-pasting a table just didn’t work at all. So… WordPress is unable to understand HTML tables. Is that really it? Well, no, again, it’s not. It just refuses to…Continue reading How to copy-paste a table from Excel to WordPress without using plug-ins?

Welcome to your new SharePoint list - now don't rename the Title field!

How to create a new SharePoint list based on a List template (.stp)?

New Microsoft Lists are here. They are awesome, and a great move by Microsoft to reap even more value of the old war horse. Wait – old war horse? Well, behind the scenes, they’re actually “just” normal SharePoint lists with a bit of added sparkles and gizmos – namely, an app, a few automations to make users’ lives easier, and an application page to display the lists. Great move by Microsoft, launch quite well done, and a pretty good user experience so far. But it’s…Continue reading How to create a new SharePoint list based on a List template (.stp)?

Welcome to your new SharePoint list - now don't rename the Title field!

How to enable saving a list as template on SharePoint Online?

Another day, another fun little task in SharePoint Online… :) This time, I needed to be able to migrate 10 or so lists with some very specific fields and plenty of content from a site to another one. What’s the best way to do that now? While PnP templates have supported exporting contents for a while now, you can still run into some issues with them – namely, fields of type “person” (or rather, “user”) are not supported, and I didn’t feel like scripting a…Continue reading How to enable saving a list as template on SharePoint Online?

Elastic Premium plan? It's got potential.

How to upgrade your Azure Function app plan when you originally selected “Consumption”?

Sometimes, you need to change the hosting model (or tier) for your resources on Azure. Maybe you’ve outgrown whatever you’ve originally selected, maybe you’ve got too much cash on your hands, or maybe you’re like me, and you get absolutely and completely fed up with the cold starts for your Azure Function apps on Consumption plan. For these situations, you have the possibility of changing the hosting tier – the plan – you’re on. Although, this has been implemented in a disturbingly non-intuitive way! Let’s…Continue reading How to upgrade your Azure Function app plan when you originally selected “Consumption”?

An accurate depiction of a NuGet package factory

Azure DevOps Pipelines Caching

Azure DevOps pipelines have a pretty handy feature called Pipeline Caching. It’ll help you avoid annoyingly long NuGet package restores in your builds. And that makes sense – why would you restore packages again and again and again, if you’re not updating your dependencies meanwhile? And especially in case of CI or CD pipeline, you’ll end up having a pipeline running constantly without packages actually getting bumped up – so your NuGet task is downloading the same packages over and over again. That’s where Pipeline…Continue reading Azure DevOps Pipelines Caching

Backwards compatibility is a hell of a drug

How to recover the private key of a (.pfx) certificate?

Recently, I ran into a problem that I definitely caused myself. I had a certificate, that was created to authenticate an app against Azure AD. The encryption key for the .pfx file was, however, lost. I could just create a new certificate, configure the app service to use that and replace the old certificate… But that’s manual labor and where’s the fun in that? I preferred a solution that included a bit more coding! After a bit of googling, I found a nice, programmatic solution…Continue reading How to recover the private key of a (.pfx) certificate?

When my Azure Function doesn't build

How to fix “System.IO.FileSystem: Could not find a part of the path \AppData\Local\AzureFunctionsTools\Releases\3.17.0\workers. Value cannot be null. (Parameter ‘provider’)” when running Azure Functions locally?

Well, that title is a mouthful. But it’s the topic for today, so what can you do? That said, this article should be pretty topical, as the issue started popping up only a few days ago. Chances are it’ll be patched soon enough, but in the meantime, it’s always useful to document the fix! Problem When running or debugging Azure Functions locally, your runtime just blurts our this error and fails to compile your functions: [2021-01-11T10:28:11.495Z] A host error has occurred during startup operation ‘0d00defa-b8bd-4fb8-9794-b0e5950a4c38’.…Continue reading How to fix “System.IO.FileSystem: Could not find a part of the path \AppData\Local\AzureFunctionsTools\Releases\3.17.0\workers. Value cannot be null. (Parameter ‘provider’)” when running Azure Functions locally?

Have you tried turning it off and on again?

How to nuke the Identity Cache in Visual Studio?

This article explains one easy workaround to a lot of Visual Studio authentication issues. Personally, it’s helped me multiple times when Cloud Explorer has gotten into a weird authentication loop or Visual Studio stops seeing my MSDN subscription. And it also helps you clean up any old and unused credentials – such as the ones you only used once in 2018 to log into a customer’s Azure environment to debug an issue they had with their AppInsights extension on an app service (and that ended…Continue reading How to nuke the Identity Cache in Visual Studio?

What in tarnation (and tarnation accessories)

Fixing unexpected Microsoft.AspNetCore package errors after a dependency update

This was a fun one! Suddenly, while running or debugging my ASP.NET Core 3.1 application, I started getting errors about missing assemblies, along the lines of “FileNotFoundException: Could not load file or assembly Microsoft.AspNetCore.Components.Forms“. These DLL files were not required a minute earlier – nor did requiring them really make much sense in my mind – but there was a nonsensical, easy fix, so in the end it was all good! But let’s go through this thing in order. What was the problem now? Problem…Continue reading Fixing unexpected Microsoft.AspNetCore package errors after a dependency update

Hindsight is 2020 meme

2020 – Year Review

Like almost customary at this point, I decided to take a look at 2020 – which goals I had set for myself, if I hit them, and what happened on koskila.net during the year. And like last year, I thought I’d set myself a few new goals! In my last year review post, I commented on 2019: 2019 was borderline tumultuous – in 2020, I hope it’ll be slightly smoother sailing. Me, in my 2019 review Oof. Overall, 2020 was definitely not “smoother sailing”. But…Continue reading 2020 – Year Review

Microsoft Graph g-raph (giraffe) - the spirit animal of Microsoft Graph

Graph API throws “$count is not currently supported.” when you KNOW it’s supported?

Hey, another funny case. “Funny” as in “the error message is misleading and googling didn’t really help”, but also as in “a colleague knew the answer right off the bat because he already fixed it in another project”. This time the documentation was in fact there, it just wasn’t there to be found. Anyway – what have I broken this time? Problem When you’re calling Graph API with both $filter and $count, for example like this: Instead of the expected number of found items, you…Continue reading Graph API throws “$count is not currently supported.” when you KNOW it’s supported?

Entity Framework Core logo

“An assembly specified in the application dependencies manifest was not found” when running Add-Migration in Entity Framework Core?

Another quick one – I’m sure this doesn’t apply to all cases, but I’m still logging it in case someone (like myself) stumbles upon the issue and finds help here. I was building a solution with some Azure Functions fetching and populating data in a database, and was planning on building an UI for browsing the data at some point later on – but I actually got stuck on the second step already :) While adding the database to my project, while running Add-Migration in…Continue reading “An assembly specified in the application dependencies manifest was not found” when running Add-Migration in Entity Framework Core?

Azure Active Directory (Azure AD)

How to fix Visual Studio Cloud Explorer being unable to access your subscriptions?

This article will describe a number of fixes to a situation, where your Visual Studio Cloud Explorer fails to show you the Azure Subscriptions you (should) have access to. Problem Your Cloud explorer might load for a long while, and finally fail to display anything meaningful. Instead, you might see an error like below: Solution This one was not fun. There are quite a few different reasons why your Visual Studio might suddenly struggle with your accounts. Below, I’ll explain a couple of steps you…Continue reading How to fix Visual Studio Cloud Explorer being unable to access your subscriptions?