Clean a string for Range Names – Regular Expressions


I am a big fan of using named  ranges in my VBA code. It makes referring to cells in formulas easy, and I can also helps in auditing the code. For instance, I can simply search for “RangeName” (including the quotes)  to see if that particular range name is being used in my code.

List Files in a Folder and Rename them – Batch Renamer


Some of the tasks I had to do at work involved running a couple of “master” spreadsheet models every month for new market conditions, for a lot of clients. Running the models took ages, but the part I loathed the most was, I had to rename each workbook individually. I figured, my time is far too valuableContinue reading “List Files in a Folder and Rename them – Batch Renamer”

Extract the Nth word in a String in Excel


Visual Basics for Applications (VBA) allows users to build on the existing functionality of  Microsoft Excel. It comes with a strong set of inbuilt functions that are often not readily accessible from Excel’s interface. These functions have to be wrapped inside a user defined function to be usable in Excel. A classic example is theContinue reading “Extract the Nth word in a String in Excel”

Concatenate a Range of Strings in Excel


Most of us have used the Concatenate() function in Excel. It is a neat function that saves you the trouble of keying in “&” between the range addresses. The only thing that would make this awesome would be the ability to concatenate an entire range. That would be way more useful than having to commaContinue reading “Concatenate a Range of Strings in Excel”