Excel 2010 Tutorial - Macros

In this video from the Excel 2010 Tutorial series, School of Technology Program Coordinator, Justin Denton, teaches us all about macros in Microsoft Excel 2010. This tutorial video is a great beginning step to your courses in technology at Rasmussen College.


So the next one we're going to get into is macros. I'll show you the quick and easy for macros. There's a really hard aspect to macros, and I'll lightly touch on that.

So I want to create a macro. On the View tab, we've got that hidden macros button that a lot of people didn't like to touch. You can go ahead and touch it.

We'll use the Record Macro button. It's really the simplest and easiest way, especially if you're working with macros. You need to build a basic macro first. And sometimes it's easier just to record some of the basic routines and then go back in and modify them.

So in this instance, I'm going to record it. So I hit record. We'll call it Macro1. That's fine. And then it's basically-- at this point, it's like a movie. It's recording everything I'm doing.

So I'll right click. I'll delete this column. I'll delete this column. Maybe I want to move-- cut this column. Paste it over here. I don't need an ID column. So, hold on, let me delete this too. I don't need this blank column. And let's say I'm done.

So I just wanted to make some quick reports. So I pulled in that data feed. I wanted to clean it up a little bit. I cleaned it up to the way I wanted it to look like. So after I've done that, now I can hit Stop Recording. So it's recorded everything that I just did. And as it did it, it just saved all that. So now I can undo all those. There we go. Have that same report. I just pulled in that new data feed. I've got my macro already built.

So I'm going to view my macros. I'll select that one that I created and hit Run. And I'm done. And it'll automatically format it all for me. So I never have to go back through all the process of cleaning up the columns anymore. I do it the one time and then forget about it. Because every time I pull in my data feed, I can just hit the record button. It's a really quick and easy way to say, OK, I know macros. I recorded a macro.

There's the more in-depth piece. And what you'll need to do when you go to get into the more in-depth piece. By default, they don't allow the developers tab in Microsoft Excel. To enable that, you actually have to click on File and Options. Customize Ribbon. And then you'll have this option here for Developers Tab. You have to select that. And that'll give you this whole set of really cool tools that'll make you nervous to mess around with.

So if I select that tool. I hit OK. And now I have this new Developer tab that just appeared. In here, it's got the same Record Macros option. But there's all these other features in here that you can work with. What we'll do is we'll just work with the macro that we created.

So if I go into macros, I've got the macro I created. I want to edit it. And this is the thing that-- there's entire classes on this piece because there's so much you can modify. This is actually Visual Basic for application programming language. So everything that we recorded, it wrote the code for automatically. So that's why, if you already know the process, you can automatically record everything.

In here, you're going to go through and modify this a little bit. Maybe I don't want to select this column. Or maybe I don't want to-- where it says Cut Copy mode, false. Maybe I don't want to use this whole section. Now, you'll see where it says selection.delete, shift to the left. So what it does, in this selection, it cut the column and shifted it to the left. It makes a little bit of sense when you actually start looking at it.

Well, you have the ability to add to this too. So if I want to add maybe a message box, I'm going to do message box. And it's just the normal hello world thing. Hello world. I want to add that into my macro. So I'll close out. And I'll click Run. So now it'll tell me hello world, or you're about to run the macro, or something. I'll hit OK, and then it'll run the macro.

There's input boxes and all this other stuff you can start working with. But the general-- I wanted to make sure that we kind of go through this really quick. But that's the general gist of doing macros. There's some sample code in the spreadsheet. There's also some websites at the last page that'll give you additional information about all the different types of Visual Basic application code. But if I go too much in it, then it'll be too much. And then that's all you'll want to do is program, right?

External links provided on Rasmussen.edu are for reference only. Rasmussen College does not guarantee, approve, control, or specifically endorse the information or products available on websites linked to, and is not endorsed by website owners, authors and/or organizations referenced.

Kendall is an Online Community Specialist at Collegis Education who oversees online communities on behalf of Rasmussen College. She has a passion for social media and enjoys motivating and encouraging former, current and future learners.

Receive Personalized Information Today

  • Personalized financial aid
  • Customized support services
  • Detailed program plan
  • Attend a no-obiligation Nursing Information Session
  • Meet the Dean of Nursing
  • Enrollment application
  • Personalized financial aid
  • Career path guidance

How may we contact you?

Please complete all fields

What would you like to study?

The program you have selected is not available in your area. Please select another program of interest.

By requesting information, I authorize Rasmussen College to contact me by email, phone or text message at the number provided.

Share Your Story Ideas
Our campuses and online community have stories to tell and we want to hear them! Did your campus raise the most money in the community for an organization? Do you have online study tips for other students? Would you like to share a personal success story about overcoming an obstacle while earning your degree?
To have your story idea considered:
  • You must be a faculty member, current student or graduate
  • Story ideas must be regarding Rasmussen College or an inspiring story about a student at Rasmussen College
  • Your submission must be original and may not have been published elsewhere online already
Please Note: Your story idea may be featured on the Rasmussen College News Beat or on one of our social networks. A member of our news team will contact you should we move forward with a blog post.
Feel free to suggest an idea for a blog post to be featured on the Rasmussen College News Beat by filling out the form below:

First Name: (required)

Last Name: (required)

Email Address: (required)

Phone Number: (required)

500 characters or less


Your Story Idea Has Been Submitted

Thank you for sending us a story idea! We’re reviewing submissions and may contact you soon to learn more about your story. In the meantime, make sure to check out our current blogs to see what’s happening on campus.