Why VBA?

Photo by Franck V. on Unsplash

One of the most important skills at the moment is being an efficient user in Microsoft Excel. It is sure that most of people touched Excel from some point. Some tried to make small calculations, some tried to gather information about a specific topic. Excel is an excellent application to help you to do that. Unless you try to analyse huge amount of data, Excel would be sufficient for 99% of your work.

That’s the reason why Excel becomes very important in our lives. Absolutely learning to manipulate data with formulas is an absolute beast, however, wouldn’t you like to have a skill that would help you to automate the staff you are doing manually every day? It doesn’t even need to be in Excel. Let’s say that each day you need to send a specific e-mail to a certain distribution list. That’s where VBA (Visual Basic for Applications) comes handy. You can basically create a short code that helps you to decrease the amount of time you spend behind the computer creating the emails that need to be sent.

Besides, there is almost no computer in which the Microsoft Office applications are not installed. In many other programming languages, you need to firstly install something. You can not use Python, Java etc. unless there are installed on your computer or you want to run the script on some online platform. You can create an app using VBA that not only controls the data in your Excel but manipulates the texts in Word and generates a ready PDF file that you can also easily send someone over by using VBA. Pretty cool!

The syntax of this language is quite easy and believe me that it would help you to automate many of the things that you do during your daily work. It would also help you to understand the data that you hold in your hand and get some insight from them.

Let’s be honest. There are many problems, which are almost impossible to solve by only using the Excel formulas. And even if you manage to write a formula that gives you the solution, it sometimes becomes such long that it takes 3–4 hours to understand for the following person in case you are not around. VBA is like any other programming language. In each line of code, you can write a small comment that would help, firstly you to remember what you did and how you did, secondly for the following person to understand the logic. These lines will never be executed but help you to create documentation. And in VBA, you don’t need to write everything within one single line, you can divide the problem and then conquer.

One of the other advantages of VBA is that you can create your own formulas. You will not be limited to function library. Let’s say that you don’t like VLOOKUP very much since it doesn’t allow you to look up a value within the columns on the left side. So you can write such a function in your VBA editor and use in the future for your comfort:

Function XLOOKUP(lookFor As Variant, lookingInColumn As Range, returnColumn As Range)

XLOOKUP = WorksheetFunction.Index(returnColumn, WorksheetFunction.Match(lookFor, lookingInColumn, 0))

End Function

Now using this function, you can get the value from the left side of the lookup key. How awesome it is right?

There are absolutely so many staff you can do using VBA but I hope I could give you some insight that would encourage you to take a step further and start learning VBA.

In case you would like to discuss or you have any questions, doubts, please always feel free to reach me out directly using the Social Media links or e-mail.

Let’s finish with a good saying about Excel

“Spreadsheets are corporate poetry; when constructed elegantly enough, they can be used to communicate sophisticated ideas to audiences who wouldn’t otherwise be receptive to details.”

Eric Seufert, “Freemium Economics: Leveraging Analytics and User Segmentation to Drive Revenue (The Savvy Manager’s Guides)

Cheers

Ozan Tellioglu

Source: https://www.ozan.pl/blog/post/2

--

--

--

https://www.ozan.pl/aboutme/

Love podcasts or audiobooks? Learn on the go with our new app.

Recommended from Medium

Large-Scale Date Normalization in ArchivesSpace with Python, MySQL, and Timetwister

ELYFI staking new round start

Deploying a Django Project to Heroku

CS373 Fall 2020: Stephen Zheng

What is an API and why should you care?

Event Sourcing is Awesome!

A year in review: Building the City of Syracuse’ first Digital Services team

Normal Forms aren’t just for databases

Get the Medium app

A button that says 'Download on the App Store', and if clicked it will lead you to the iOS App store
A button that says 'Get it on, Google Play', and if clicked it will lead you to the Google Play store
Ozan Tellioğlu

Ozan Tellioğlu

https://www.ozan.pl/aboutme/

More from Medium

Wild Rift Dashboard Behind the Curtain

Power BI Calculated Column vs Measure. Which one is more important?

3 frameworks into one — Write your next paper with R Studio!

Data Table in UiPath

UiPath Data Table