VBA assessment test: free practice for job applications
Twelve tasks in 30 minutes, of the kind that can come up in VBA tests during hiring: fill cells, loop through lists, work with sheets, delete rows, handle errors. You write every macro yourself, with no sign-up, and at the end you see which topics are solid.
This is a practice test by LearnThisNext. It is not an official test by an employer, a testing company or Microsoft, and we do not know the tests of individual companies. It covers the core topics that practical VBA tasks build on. Only you see your result.
How the test works
- 12 tasks on small worksheets with everyday office data. The sheet is shown above each task.
- 30 minutes. The clock runs at the top of the test.
- Run your macro with "Run" (F5 or Ctrl+Enter) as often as you like and see the sheet afterwards. Only "Submit answer" counts. No hints, solutions or step-through, just like a real test.
- What is checked is the result on the sheet, not the wording of your code. The server also checks your macro on different data you do not see, usually with more rows. Fixed row numbers and typed-in results fail there.
- From 9 out of 12 correct tasks, which is 75 percent, we count it as a good result. For every topic that is not solid yet, you get a link to the matching lesson.
- You do not need an account. Your result is neither saved nor shared.
Every run draws new tasks, so you can take the test several times without just recognizing answers.
Which topics the test covers
Every company decides for itself what a VBA test looks like. Some send a workbook with a take-home task, others have you read and fix code in the interview, others again use an online test. The topics still tend to come from the same place, because they are the everyday core of office macros. These twelve are in the test:
| Topic | Typical task |
|---|---|
| Range and Cells, calculations | read values from cells, calculate, write the result |
| variables, MsgBox and InputBox | keep interim values, show a message with the result |
| If Then Else | a discount or approval that depends on an amount |
| For Next | process every row of a list |
| last row, For Each | work through a list of unknown length, append something at the bottom |
| Select Case, Do While | tiers and categories, a loop up to the first blank cell |
| worksheets | move values from one sheet to another, add a sheet |
| worksheet functions | SUM, AVERAGE, COUNTIF or VLOOKUP inside a macro |
| text, dates | split names, strip spaces, work out due dates |
| copying, deleting rows | move rows across, delete rows that meet a condition |
| arrays, Dictionary | total values per customer or region |
| error handling, procedures | catch an expected error, a helper procedure with arguments |
Which topics you will face depends on the role. For admin roles the top rows are often enough. If you are applying for finance or reporting, where macros build reports on a regular basis, you should also be comfortable with sheets, worksheet functions, deleting rows and the Dictionary. UserForms, files and Outlook are not part of this test, because they do not run in the browser.
Warm up: three typical tasks
Before you start the clock, you can solve three tasks here at your own pace, with hints and explanations. They come from the VBA course and are free. The first combines two conditions with And:
Task A bonus of 500 goes to anyone with sales of at least 50000 and a permanent contract (column C = "permanent"). Everyone else gets 0. Enter the bonus for row 2 in D2 and for row 3 in D3, with one If and And for each.
| A | B | C | D | |
|---|---|---|---|---|
| 1 | Name | Sales | Contract | Bonus |
| 2 | Ryan Mitchell | 62,000 | permanent | |
| 3 | Chloe Evans | 71,500 | temporary | |
| 4 | ||||
| 5 |
The second walks a list down to the last row with For Each:
Task The supplier is raising all prices by 5%. The macro RaisePrices should multiply every price in column B by 1.05, using For Each over the range from B2 down to the last row. The last row is already worked out for you.
| A | B | C | D | |
|---|---|---|---|---|
| 1 | Item | Price | ||
| 2 | Coffee beans 1 kg | 18.90 | ||
| 3 | Espresso beans 1 kg | 21.50 | ||
| 4 | Green tea, 100 bags | 6.40 | ||
| 5 | Sugar 1 kg | 1.79 | ||
| 6 | Coffee filters, pack of 100 | 2.49 | ||
| 7 | Hot chocolate powder 500 g | 4.99 |
The third calculates key figures with worksheet functions:
Task Write a macro KeyFigures that uses WorksheetFunction on the sales in column B (row 2 down to the last row) and writes the total to E2, the average to E3 and the highest value to E4.
| A | B | C | D | E | |
|---|---|---|---|---|---|
| 1 | Branch | Sales | Measure | Value | |
| 2 | Leeds | 48,200.00 | Total | ||
| 3 | Bristol | 39,750.00 | Average | ||
| 4 | Austin | 27,400.00 | Highest | ||
| 5 | Denver | 31,980.00 | |||
| 6 | Glasgow | 35,600.00 |
What matters in VBA tasks
A VBA test is rarely about obscure commands. Whoever sets the task wants to see that your macro still works when the data is not friendly, and that someone else can follow your code:
- Any list length. Find the last row instead of typing in a fixed number. Our test checks exactly that with hidden, longer data.
- Delete rows backwards. A loop that deletes going forwards skips rows. It is a well-known test of understanding.
- Catch expected errors. A lookup value is missing, a sheet does not exist, a cell holds text instead of a number. A good macro checks for that or traps the error deliberately instead of stopping with a run-time error.
- No Select. Refer to cells directly instead of selecting them first. You should be able to clean up recorded code.
- Readability.
Option Explicit, typed variables, meaningful names and indentation make your code easy to follow.
How to prepare
Take the test once without preparing. The results show which topics are still shaky. Practice exactly those lessons until you solve their exercises without hints, then do another run. If you do not know where you stand overall yet, start with the shorter skills assessment: in 20 minutes it gives you a level and the lesson to continue with. For the theory questions that come up in the interview, such as Set, ByRef or error handling, read VBA interview questions. Ready-made macros for common jobs are on VBA macro examples.
What next?
In the VBA course you practice the topics lesson by lesson, in the same editor as the test. Level 1 is free. At the end comes the VBA final test. Pass it and you get a LearnThisNext certificate in your name with a verification link for job applications and LinkedIn. It is not a Microsoft certification. Other ways to show VBA skills are compared on VBA certification.
FAQ
Is the VBA assessment test free?
Yes. You do not need an account and can take it as often as you like. Every run has new tasks.
Are these tasks from real hiring tests?
No. We do not know the tests of individual companies and do not copy test questions. The tasks are our own, in the style of typical office work.
Is my result saved?
No. You see it right after the test, then it is gone. Even when you are logged in, the test does not change your learning progress.
How is it different from the skills assessment?
The skills assessment places you on one of four levels in 20 minutes and recommends a lesson. The assessment test checks twelve topics side by side in 30 minutes, like a test in a hiring process, and shows your gaps by topic.
Do I need Excel?
No. The macros run on our server in a VBA engine of our own. All you need is a browser. If the real test takes place in Excel, it helps to have worked in the actual VBA editor (Alt+F11) beforehand.
Do I get a certificate?
Not for this practice test. A certificate with a verification link comes with the final test at the end of the VBA course.