VBA Coding

"Why should I pay your high rate when they guy down the street charges half?"

Here you can learn how high earning professional developers code VBA.

What Defines a Professional Developer?

A professional developer is someone commissioned by others to create applications. There are fundamental differences between those who create applications for themselves and those who create applications for others.

Money Pressure:

Those who commission professionals don't want to pay more than they have to, so if we are working by the hour, clients will pressure us to deliver quicker. And if we are charging flat rates by the project, our earnings potential is determined by how quickly we can deliver. Truly, time is money and if we want to earn more, we must learn to develop quickly.

Reputation Pressure:

Finding customers or a new job takes time and earns us nothing. We can earn more if each client gives us repeat business. That only happens when clients feel they are getting quality products for their money. Their feelings about us are our reputation. A quick way to get a bad reputation is to deliver poor quality applications that error or break. If we want repeat business, or if we want to remain employed, we must learn to prevent errors.

How do we go from Beginner to Professional?

Beginners can be professionals but they won't earn much until they can bypass the first two stages of developer evolution.

Start from Scratch

The first stage is Start from Scratch. This means we start with nothing, no libraries, no templates, and no reusable routines. Beginners must create 100% of the required code by typing it. This is slow and error prone.

Modify an Existing Application

The next stage starts when someone commissions us to create something very similar to a project we did before. We then copy the previous project and modify it to meet the new requirements. This may reduce our project's hand typed code by as much as 80%. Thus, we can deliver projects much faster and with less errors. Unfortunately, this is limited to when we have similar applications in our portfolio.

Assemble from Code Libraries

The last stage starts when we realize all applications have similarities. Even if we have never created anything like what our client is asking for, with compact, battle-tested, reusable functions grouped into libraries (modules) by functionality, we simply include those libraries meeting our project's requirements and then add the 20% or less of custom code required to integrate the various routines as needed. Our effort is cut by as much as 80% for just about any project, even ones we have never done anything similar.

How do we get Code Libraries?

We can download some libraries free from GitHub. You can download or copy routines from here. Or if we have enough money, we can buy them. But more often than not, we must create them. To create them we should follow the principles of software engineering. These principals are language agnostic which means we can employ many of them in VBA. They include:

Plan First

Before writing any code:

  • Understand our customers expectations and determine deliverables that will meet those expectations.

  • For each deliverable, determine the tasks required to create them (aka Functional Decomposition).

Don't Repeat Yourself (DRY)

Looking across all deliverables, find which tasks are the same. Combine identical tasks into one function and call that function where needed.

Keep It Simple, Smart (KISS)

I know that is not exactly what K.I.S.S. means, but I prefer the implication. Create smart routines that do just one thing. For example, if we need to create a table, create a routine that just creates the table. Create a separate routine to add a record and yet another routine to delete a record. And if our project doesn't require deleting records, don't create that function. This also is known as the Single Responsibility principle.

There are many other principles and while I encourage every developer learn them all, in these posts I will concentrate less on theory and more on implementation so we can create error free, reusable routines from which to build libraries so we can start assembling projects from components as soon as possible.


Conclusion

You may never work in an IT department, but I guarantee that working like a professional developer will improve the quality of your work and, over time, greatly speed application development making you more valuable than your competition. So when a prospective client asks, "Why should I pay your high rate when they guy down the street charges half?" You can answer...

"Because I will deliver in a tenth of the time so your project costs less and you realize benefits sooner."

Next lesson: The VBA Editor