Task 1 – Maze Recording

Actuary Forums Forums Learnings Softwares Excel VBA Task Macros Recording macros and buttons Task 1 – Maze Recording

  • This topic is empty.
Viewing 1 post (of 1 total)
  • Author
    Posts
  • #22705
    Mayank Goyal
    Keymaster

      Using Microsoft Excel to record macros to take the strain out of repetitive tasks.

      Answer is given in the file itself

      [attachment=0]Task 1 – Maze Recording.zip[/attachment]

      you’ll need to login and download and unzip the attached file

      Open the file found in the folder above.Record 4 macros to work as follows:

    • A new macro called Down, such that when you press CTRL + D the macro takes you down one cell.

    • A new macro called Up, such that when you press CTRL  + U the macro takes you up one cell.

    • A new macro called Left, such that when you press CTRL + L the macro takes you left one cell.

    • A new macro called Right, such that when you press CTRL + R the macro takes you right one cell.

      Test your macros out by starting in cell B2 and pressing the appropriate sequence of keys:

       The first sequence of keys is:CTRL  + D

       Now record a fifth macro called Cheat, which takes you straight to the cell containing the gold, regardless of your current starting position.

       Think carefully about whether you should be recording in relative or absolute mode.

       Add some buttons to your workbook to make these macros easier to run like UP, DOWN, RIGHT, LEFT and CHEAT

      The buttons do not have to be perfectly aligned.

      Answer: Try it yourself using & answer is given in the workbook itself.

      [attachment=0]Task 1 – Maze Recording.zip[/attachment]

      https://support.office.com/en-us/article/Assign-a-macro-to-a-Form-or-a-Control-button-d58edd7d-cb04-4964-bead-9c72c843a283

      http://www.info-stat.com/XLVBA-Navigate02.htm

       

    Viewing 1 post (of 1 total)
    • You must be logged in to reply to this topic.

    Actuary Forums Forums Learnings Softwares Excel VBA Task Macros Recording macros and buttons Task 1 – Maze Recording