How to set an Excel spreadsheet column width with VBA?

Updated: August 2021; Works on Excel 365, 2019, 2016. In today’s Excel automation tutorial we will learn how to quickly change the width of a worksheet column as needed – but programmatically using VBA (Visual Basic for Applications). Prerequisites In order to write VBA code, you’ll need to first and foremost, ensure that your developer … Read more

How to make a Macro in Microsoft Visio?

Here’s a question from Danny: I have recently started using Microsoft Visio to make use of diagrams, layouts, and charts. I understood that i can improve my productivity by automating much of the common work across different diagram / drawing files by using Office Macros. As i am pretty new to VBA development, i would … Read more

How to work with Message and Input Boxes in PowerPoint VBA?

Going through the comments, i have seen a couple of reader questions on how to work with Visual Basic Input and Message boxes in PowerPoint. In this tutorial we’ll provide a very basic foundational knowledge to help you use those capabilities when automating your presentation creation. Setting up the Developer Tab First off, we’ll need … Read more

How to subset a dataframe by one or multiple columns?

When trying to make sense of a large DataFrame in Pandas, you might need to subset it by columns and rows. In this tutorial we’ll show the most prevalent use cases of column partitioning your DataFrame. We’ll start by setting up our example DataFrame, which we’ll do by running the following Python code in our … Read more

How to create and insert shapes in PowerPoint with VBA?

Couple days ago, i wanted to automate the rather mundane task of creating some PowerPoint slides. When automating PowerPoint you typically work with the Slides and Shapes collection. Slides is rather self explanatory, and shapes is pretty much everything else including text boxes, action buttons, media objects, labels, pictures, callouts, flowcharts and so on and … Read more