Read our blogs, tips and tutorials
Try our exercises or test your skills
Watch our tutorial videos or shorts
Take a self-paced course
Read our recent newsletters
License our courseware
Book expert consultancy
Buy our publications
Get help in using our site
551 attributed reviews in the last 3 years
Refreshingly small course sizes
Outstandingly good courseware
Whizzy online classrooms
Wise Owl trainers only (no freelancers)
Almost no cancellations
We have genuine integrity
We invoice after training
Review 30+ years of Wise Owl
View our top 100 clients
Search our website
We also send out useful tips in a monthly email newsletter ...
You are welcome to try any of the 28 Advanced VBA exercises listed below, but please do not distribute them in any form without asking for our written permission first.
Software: | Advanced VBA |
Topic: | Revision of VBA |
Level: | Relatively easy |
Exercise: | Loop over film cells, picking out those films having lots of reviews and colouring them. |
Software: | Advanced VBA |
Topic: | Revision of VBA |
Level: | Relatively easy |
Exercise: | Write a macro to loop over a number of holidays, getting the details for each and writing these out to the immediate window. |
Software: | Advanced VBA |
Topic: | Revision of VBA |
Level: | Average difficulty |
Exercise: | An exercise to loop over collections of characters in a Word paragraph. |
Software: | Advanced VBA |
Topic: | Revision of VBA |
Level: | Average difficulty |
Exercise: | List out the number of shapes on each slide in a presentation, by looping over the slides. |
Software: | Advanced VBA |
Topic: | Links to other applications |
Level: | Relatively easy |
Exercise: | Create a PowerPoint macro writing slide information for an existing presentation to a new workbook in Excel. |
Software: | Advanced VBA |
Topic: | Links to other applications |
Level: | Relatively easy |
Exercise: | Loop over cells in Excel, copying contents to Word bookmarks to write a letter. |
Software: | Advanced VBA |
Topic: | Links to other applications |
Level: | Average difficulty |
Exercise: | Looping over words in a document, writing each to Excel and counting instances. |
Software: | Advanced VBA |
Topic: | FileSystemObjects |
Level: | Relatively easy |
Exercise: | Write a macro which creates a FileSystemObject reference, then uses this to list out all of the Excel workbooks in a folder. |
Software: | Advanced VBA |
Topic: | FileSystemObjects |
Level: | Average difficulty |
Exercise: | Using FileSystemObjects to move, copy, rename and delete files and folders. |
Software: | Advanced VBA |
Topic: | FileSystemObjects |
Level: | Average difficulty |
Exercise: | Write a macro to open lots of workbooks in turn, collating the responses from each. |
Software: | Advanced VBA |
Topic: | FileSystemObjects |
Level: | Harder than average |
Exercise: | Consolidate data from files on your computer using file references. |
Software: | Advanced VBA |
Topic: | Working with text files |
Level: | Relatively easy |
Exercise: | Write a macro to loop over the lines in a text file, reading each in and storing the message. |
Software: | Advanced VBA |
Topic: | Working with text files |
Level: | Average difficulty |
Exercise: | Read in a text file which contains the specification of a house, and colour Excel cells accordingly to draw it. |
Software: | Advanced VBA |
Topic: | FileDialogs |
Level: | Relatively easy |
Exercise: | Using FileDialogs to create customised file dialog boxes. |
Software: | Advanced VBA |
Topic: | Class modules |
Level: | Relatively easy |
Exercise: | Create a class to allow users to run a mortgage model (properties are things like house price and deposit). |
Software: | Advanced VBA |
Topic: | Class modules |
Level: | Average difficulty |
Exercise: | Create a class to allow you to create simple pie charts. The chart has 3 simple properties - title, data range and slice to explode - and one method, print preview. |
Software: | Advanced VBA |
Topic: | Advanced class modules topics |
Level: | Harder than average |
Exercise: | An exercise to create a Holiday class and a strongly-typed Holidays collection, and test that these work. |
Software: | Advanced VBA |
Topic: | Linking to data |
Level: | Average difficulty |
Exercise: | Create an input form for Beatles, linking Excel to Access using ADO, then read Beatles back into an array using REDIM PRESERVE. |
Software: | Advanced VBA |
Topic: | Linking to data |
Level: | Average difficulty |
Exercise: | Use ADO in VBA to add data to an Access database from an Excel workbook. |
Software: | Advanced VBA |
Topic: | Linking to data |
Level: | Average difficulty |
Exercise: | Use ADO to extract a table of world events from an Access database into a new Excel worksheet. |
Software: | Advanced VBA |
Topic: | Passing arguments |
Level: | Relatively easy |
Exercise: | Create a couple of simple macros taking arguments - one to display a message, and one to protect or unprotect a worksheet. |
Software: | Advanced VBA |
Topic: | Passing arguments |
Level: | Relatively easy |
Exercise: | Create a routine to send an Outlook message. The argument list should vary according to whether you are copying the message to anyone. |
Software: | Advanced VBA |
Topic: | Passing arguments |
Level: | Average difficulty |
Exercise: | Create a function to calculate Olympic medal points - this should take 3 arguments and return a single points total. |
Software: | Advanced VBA |
Topic: | Passing arguments |
Level: | Average difficulty |
Exercise: | Writing a program to calculate the factorial of a number without loopin, using recursive programming. |
Software: | Advanced VBA |
Topic: | Passing arguments |
Level: | Harder than average |
Exercise: | Write a macro to calculated breadcrumbs for a table of regions. Each region record contains the region id and name and the id of the parent region. |
Software: | Advanced VBA |
Topic: | Working with shapes |
Level: | Relatively easy |
Exercise: | Write a macro to put block arrow shapes into different cells for Little Red Riding Hood. |
Software: | Advanced VBA |
Topic: | Working with shapes |
Level: | Average difficulty |
Exercise: | Write a macro to generate all of the autoshapes in a worksheet. |
Software: | Advanced VBA |
Topic: | Working with shapes |
Level: | Harder than average |
Exercise: | Draw car shapes using a macro, and use them to simulate a race. |
You can search our full list of VBA exercises here. Or why not learn to do them the right way on one of our VBA training courses? You can attend our online training classes wherever you are in the world!
Kingsmoor House
Railway Street
GLOSSOP
SK13 2AA
Landmark Offices
99 Bishopsgate
LONDON
EC2M 3XD
Holiday Inn
25 Aytoun Street
MANCHESTER
M1 3AE
© Wise Owl Business Solutions Ltd 2024. All Rights Reserved.