Microsoft Visual Basic
Selecting cells exercise
Relatively easy

This Microsoft Visual Basic SELECTING CELLS exercise is provided to allow potential course delegates to assess their suitability for the Wise Owl EXCEL VISUAL BASIC course only, and may not be reproduced in whole or in part in any format without the prior written consent of Wise Owl.

Exercise: Writing macros to offset one cell within maze

A full answer to this exercise is provided as part of the training course!

1) Download the files needed to start this exercise: exercise-117.zip (and click here if you experience any problems unzipping this file after downloading it).
2) Write (as opposed to recording) four new macros as follows:
  • A macro called Down, which takes you down one cell
  • A macro called Up, which takes you up one cell
  • A macro called Left, which takes you left one cell
  • A macro called Right, which takes you right one cell
3) Assign short-cut keys to each macro (for example, you might assign SHIFT + CTRL + D to the Down macro).
Training exercise hint You can only assign a short-cut key from within Excel.  From the menu select Tools / Macro / Macros... , select a macro and click on the Options... button at the bottom right.
4) Starting at cell B2, run the short-cut keys in the order dictated by the maze to reach the gold:
Exercise screen-shot 1000 Your macros should take you to the gold!
5) Save your workbook and close it down.

Thank you for showing an interest in this Excel Visual Basic training course! As mentioned above, full answers to this and other exercises are provided on the course. On all Wise Owl scheduled courses delegates can take away these model answers (together with their own efforts!) on a free USB stick.

All content copyright Wise Owl Business Solutions Ltd 2008.  All rights reserved..